<!DOCTYPE HTML PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"><head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8"><title>
	
  Deploying a Visual Studio Tools for the Office System 3.0 Solution for
 the 2007 Microsoft Office System Using Windows Installer (Part 1 of 2)

</title><link 
href="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/064bc0ac7f2dacac51404ce41f8aa35b.css"
 rel="stylesheet" type="text/css"><link rel="alternate" media="print" 
href="http://msdn.microsoft.com/en-us/library/cc563937%28d=printer,v=office.12%29.aspx"><meta
 name="DCS.dcsuri" 
content="/en-us/library/cc563937(d=lightweight,l=en-us,v=office.12).aspx"><meta
 name="NormalizedUrl" 
content="http://msdn.microsoft.com/en-us/library/cc563937(d=lightweight,l=en-us,v=office.12).aspx"><meta
 name="DCSext.Title" content="Deploying a Visual Studio Tools for the 
Office System 3.0 Solution for the 2007 Microsoft Office System Using 
Windows Installer (Part 1 of 2)"><meta name="DCSext.ContentType" 
content="MSDN_OFFICETECHARTICLE"><meta name="DCSext.Product" 
content="MSDN_OFFICEVSTO"><meta name="DCSext.ProductFamily" 
content="MSDN_OFFICE"><meta name="VotingContextUrl" 
content="http://msdn.microsoft.com/en-us/library/cc563937(d=lightweight,l=en-us,v=office.12).aspx"><meta
 name="MN" content="D1DC1169-3:25:54 PM"><meta name="Search.ShortId" 
content="cc563937"><meta name="Ms.Locale" content="en-us"></head><body><div
 class="header"><table class="headerBar cl_lightweight_topnav_slice" 
border="0" cellpadding="0" cellspacing="0"><tbody><tr><td 
class="leftSection cl_lightweight_header_leftSection_wave 
leftSectionImageClusterOverride"><div class="tabContainer"><a 
href="http://msdn.microsoft.com/en-us/" title="Home" class=" headerTab">Home</a><a
 href="http://msdn.microsoft.com/en-us/library" title="Library" 
class="headerTabSelected cl_lightweight_selected_tab_repeatX ">Library</a><a
 href="http://msdn.microsoft.com/en-us/bb188199.aspx" title="Learn" 
class=" headerTab">Learn</a><a 
href="http://msdn.microsoft.com/en-us/aa570309.aspx" title="Downloads" 
class=" headerTab">Downloads</a><a 
href="http://msdn.microsoft.com/en-us/aa570318.aspx" title="Support" 
class=" headerTab">Support</a><a 
href="http://msdn.microsoft.com/en-us/aa497440.aspx" title="Community" 
class=" headerTab">Community</a></div></td><td class="rightSection 
cl_lightweight_header_rightSection_wave 
rightSectionImageClusterOverride"><div class="tabContainer"><a 
href="http://login.live.com/login.srf?wa=wsignin1.0&amp;rpsnv=11&amp;ct=1284762354&amp;rver=6.0.5276.0&amp;wp=MCLBI&amp;wlcxt=msdn%24msdn%24msdn&amp;wreply=http:%2F%2Fmsdn.microsoft.com%2Fen-us%2Flibrary%2Fcc563937%2528office.12%2529.aspx&amp;lc=1033&amp;cb=&amp;id=254354"
 title="Sign in">Sign in </a><span class="pipe">|</span><a 
href="http://msdn.microsoft.com/en-us/library/preferences/locale/?returnurl=%252fen-us%252flibrary%252fcc563937%28v%253doffice.12%29.aspx"
 title="United States - English">United States - English </a><span 
class="pipe">|</span><a 
href="http://msdn.microsoft.com/en-us/library/preferences/experience/?returnurl=%252fen-us%252flibrary%252fcc563937%28v%253doffice.12%29.aspx"
 title="Preferences">Preferences</a></div></td></tr></tbody></table></div><div
 class="contentPlaceHolder"><div class="navigation" id="Navigation" 
style="width: 0px;"><div class="searchcontainer"><form id="SearchForm" 
action="http://social.msdn.microsoft.com/Search/en-us" method="get" 
style="margin: 0pt; padding: 0pt;"><div class="searchBoxContainer" 
style=""><table class="searchBox" border="0" cellpadding="0" 
cellspacing="0"><tbody><tr><td><img 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/030c41d9079671d09a62d8e2c1db6973.gif"
 class="cl_lt_search" alt=""></td><td class="searchTextBoxTd 
cl_slice_Search"><input id="Text1" maxlength="200" class="searchTextBox"
 name="query" value="Search MSDN with Bing" onfocus="document.onkeydown =
 ''; WatermarkFocus(this, 'Search MSDN with Bing', 'searchTextBoxTrue') "
 onblur="document.onkeydown = Presskey;WatermarkBlur(this, 'Search MSDN 
with Bing', 'searchTextBox')" type="text"></td><td class="searchButtonTd
 cl_slice_Search"><a href="#" style="display: block; overflow: hidden; 
width: 19px; height: 19px; position: relative; padding: 0pt; margin: 
0pt;" 
onclick="javascript:document.getElementById('SearchForm').submit();"><img
 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/0988b66c1e448ee567fca35fa16b4f24.png"
 class="cl_search_icon" style="position: relative;" title="Search" 
alt="Search"></a></td><td><img 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/030c41d9079671d09a62d8e2c1db6973.gif"
 class="cl_rt_search" alt=""></td></tr></tbody></table></div></form></div><div
 class="navcontainer"><div class="nav"><div class="toclevel0 ancestry"><div
 class="clip5x9 nav_root"><img 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/0988b66c1e448ee567fca35fa16b4f24.png"
 class="cl_nav_bullet" alt=""></div><div class="nav_div_currentroot"><a 
href="http://msdn.microsoft.com/en-us/library/ms123401.aspx" title="MSDN
 Library">MSDN Library</a></div><div class="clip5x9 nav_arrows"><img 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/0988b66c1e448ee567fca35fa16b4f24.png"
 class="cl_nav_arrow" alt=""></div><div class="nav_div_currentroot"><a 
href="http://msdn.microsoft.com/en-us/library/bb726434%28v=office.12%29.aspx"
 title="Office Development">Office Development</a></div><div 
class="clip5x9 nav_arrows"><img 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/0988b66c1e448ee567fca35fa16b4f24.png"
 class="cl_nav_arrow" alt=""></div><div class="nav_div_currentroot"><a 
href="http://msdn.microsoft.com/en-us/library/bb726436%28v=office.12%29.aspx"
 title="2007 Microsoft Office System">2007 Microsoft Office System</a></div><div
 class="clip5x9 nav_arrows"><img 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/0988b66c1e448ee567fca35fa16b4f24.png"
 class="cl_nav_arrow" alt=""></div><div class="nav_div_currentroot"><a 
href="http://msdn.microsoft.com/en-us/library/bb871648%28v=office.12%29.aspx"
 title="Visual Studio Tools for the Office System (3.0)">Visual Studio 
Tools for the Office System (3.0)</a></div><div class="clip5x9 
nav_arrows"><img 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/0988b66c1e448ee567fca35fa16b4f24.png"
 class="cl_nav_arrow" alt=""></div><div class="nav_div_currentroot"><a 
href="http://msdn.microsoft.com/en-us/library/dd186137%28v=office.12%29.aspx"
 title="Technical Articles">Technical Articles</a></div></div><div 
class="clip13x9 nav_dots_current"><img 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/0988b66c1e448ee567fca35fa16b4f24.png"
 class="cl_nav_dots" alt=""></div><div class="toclevel1 current"><a 
href="http://msdn.microsoft.com/en-us/library/cc563937%28v=office.12%29.aspx"
 title="Deploying a Visual Studio Tools for the Office System 3.0 
Solution for the 2007 Microsoft Office System Using Windows Installer 
(Part 1 of 2)">Deploying a Visual Studio Tools for the Office System 3.0
 Solution for the 2007 Microsoft Office System Using Windows Installer 
(Part 1 of 2)</a></div><div class="toclevel2 children" 
style="border-bottom: 1px solid rgb(187, 187, 187);"></div><img 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/030c41d9079671d09a62d8e2c1db6973.gif"
 alt="Separator" class="communityContentNavigationSeparator 
cl_lt_cc_line_top"><div class="communityContentNavigation"><div 
class="communityContentNavigationHeader">Community Content</div><div 
class="communityContentNavigationPost"><div 
class="communityContentNavigationAvatarContainer"><a 
class="communityContentNavigationLinkAvatar" href="#21" title=""><img 
alt="" class="cl_default_avatar" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/Image_009.avatr"></a></div><div
 class="communityContentNavigationLink"><ul><li><a href="#21" title="">Excellent
 Article</a></li><li>This&nbsp;is&nbsp;the&nbsp;best&nbsp;article&nbsp;I&nbsp;have&nbsp;...</li></ul></div></div><div
 class="communityContentNavigationPost"><div 
class="communityContentNavigationAvatarContainer"><a 
class="communityContentNavigationLinkAvatar" href="#20" title=""><img 
alt="" class="cl_default_avatar" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/Image_019.avatr"></a></div><div
 class="communityContentNavigationLink"><ul><li><a href="#20" title="">Adding
 Add-in without setup proj...</a></li><li>How&nbsp;to&nbsp;add&nbsp;VSTO&nbsp;addins&nbsp;to&nbsp;excel&nbsp;...</li></ul></div></div><div
 class="communityContentNavigationMoreLink"><a href="#CommunityContent" 
title="More...">More...</a></div></div></div></div></div><a href="#" 
onclick="onIncreaseToc()" class="tocResize" id="TocResize" style="left: 
0px;"><img style="" id="ResizeImageIncrease" class="cl_nav_resize_open" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/0988b66c1e448ee567fca35fa16b4f24.png"
 onmousedown="onIncreaseToc()" title="Expand" alt="Expand"><img 
id="ResizeImageReset" class="cl_nav_resize_close" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/0988b66c1e448ee567fca35fa16b4f24.png"
 style="display: none;" onmousedown="onResetToc()" title="Minimize" 
alt="Minimize"></a><div class="content"><div class="clip117x31 logo"><a 
href="http://msdn.microsoft.com/en-us/library/default.aspx"><img 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/0988b66c1e448ee567fca35fa16b4f24.png"
 class="msdn_body_logo" alt="" title=""></a></div><img 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/4af07a4b382aa20acda1ffb4bb75c973.png"
 class="TOC_Fade_Top" alt=""><div class="topicContainer"><div 
class="topic" xmlns="http://www.w3.org/1999/xhtml"><h1 class="title">Deploying
 a Visual Studio Tools for the Office System 3.0 Solution for the 2007 
Microsoft Office System Using Windows Installer (Part 1 of 2)</h1><div 
class="lw_vs"><div id="curversion"><strong>
            Office 2007</strong></div></div><div id="mainSection"><div 
id="mainBody"><p><strong>Summary:</strong> Learn how to deploy a 
Microsoft Visual Studio Tools for the Office system 3.0 add-in or 
document-level solution using a Visual Studio 2008 setup project to 
create a Windows Installer package that targets the 2007 Microsoft 
Office system. (29 printed pages)</p><p>Wouter van Vugt, Code Counsel</p><p>Ted
 Pattison, Ted Pattison Group</p><p><strong>Applies to:</strong>  
Microsoft Visual Studio Tools for the Microsoft Office system 3.0, 2007 
Microsoft Office system, Visual Studio 2008</p><p><strong>Download:</strong><span
 class="unresolvedLink">http://code.msdn.microsoft.com/VSTO3MSI</span></p><p><strong>Contents</strong></p><ul><li
 class="unordered"><a href="#VSTO3SolutionPart1_Overview">Overview</a><br><br></li><li
 class="unordered"><a href="#VSTO3SolutionPart1_DeploymentMethods">Deployment
 Methods</a><br><br></li><li class="unordered"><a 
href="#VSTO3SolutionPart1_DeployingVisualStudioToolsfortheOfficesystem30solutions">Deploying
 Visual Studio Tools for the Office system 3.0 solutions</a><br><br></li><li
 class="unordered"><a 
href="#VSTO3SolutionPart1_DownloadSamplesProvidedwiththisArticle">Download
 Samples Provided with this Article</a><br><br></li><li 
class="unordered"><a 
href="#VSTO3SolutionPart1_PreparingyourDevelopmentComputer">Preparing 
your Development Computer</a><br><br></li><li class="unordered"><a 
href="#VSTO3SolutionPart1_CreatingtheAddinProject">Creating the Add-in 
Project</a><br><br></li><li class="unordered"><a 
href="#VSTO3SolutionPart1_CreatingaBasicInstaller">Creating a Basic 
Installer</a><br><br></li><li class="unordered"><a 
href="#VSTO3SolutionPart1_KnownIssues">Known Issues</a><br><br></li><li 
class="unordered"><a href="#VSTO3SolutionPart1_Conclusion">Conclusion</a><br><br></li><li
 class="unordered"><a href="#VSTO3SolutionPart1_AdditionalResources">Additional
 Resources</a><br><br></li><li class="unordered"><a 
href="#VSTO3SolutionPart1_AbouttheAuthors">About the Authors</a><br><br></li></ul><a
 id="VSTO3SolutionPart1_Overview"></a><h1 class="heading">Overview</h1><div
 id="sectionSection0" class="section"><p>You can develop a Visual Studio
 Tools for the Office system 3.0 solution for the 2007 Microsoft Office 
system, and deploy the solution by using a Visual Studio 2008 Setup 
project to create a Windows Installer package. The discussion includes 
steps for deploying a simple add-in, including additional files and 
components, and trusting the solution. This applies to both 
application-level add-ins and document-level solutions.</p><p>For a 
discussion about how to deploy a solution targeting Microsoft Office 
2003 see <a 
href="http://msdn.microsoft.com/en-us/library/bb332052%28v=office.12%29.aspx">Deploying
 Visual Studio 2005 Tools for the Office System SE Solutions Using 
Windows Installer: Walkthroughs (Part 2 of 2)</a>. Note that when you 
install Visual Studio 2008 you install both Visual Studio Tools for the 
Office system 3.0 for targeting the 2007 Microsoft Office system as well
 as Visual Studio 2005 Tools for the Office System Second Edition to 
target Microsoft Office 2003. </p></div><a 
id="VSTO3SolutionPart1_DeploymentMethods"></a><h1 class="heading">Deployment
 Methods</h1><div id="sectionSection1" class="section"><p>You can use 
ClickOnce to create and install self-updating applications with minimal 
user interaction. This has an automated mechanism for easily 
distributing updates to your application. However, ClickOnce is not 
capable of deploying additional components such as Visio stencils or 
additional registry keys. It is also possible the customization is part 
of a greater project where using ClickOnce may be unwanted.</p><p>Besides
 ClickOnce, you can also use Windows Installer to deploy a Visual Studio
 Tools for Office customization. Windows Installer allows you to 
configure the deployment in great detail, but this does require more 
effort to configure correctly. You lose the simple ease of deploying 
using ClickOnce technology and advantages such as automated updates, but
 you receive benefits such as branding and configurability. You can also
 combine these two technologies by having your Windows Installer setup 
file call into the ClickOnce installation tool provided with Visual 
Studio Tools for Office.</p><p>For an overview of how to deploy a Visual
 Studio Tools for the Office system 3.0 solution using ClickOnce, see <a
 
href="http://msdn.microsoft.com/en-us/library/bb821233%28v=office.12%29.aspx">Deploying
 Solutions for the 2007 Office System with ClickOnce Using Visual Studio
 2008 Professional</a>.</p><p>The following table shows various 
advantages and disadvantages of these two deployment methods related to 
Visual Studio Tools for Office. For a complete overview of the benefits 
of each deployment technology, see <span class="unresolvedLink">Choosing
 Between ClickOnce and Windows Installer</span>.</p><h3 
class="subHeading">Table 1. Advantages and disadvantages of the 
available deployment methods</h3><table><tbody><tr><th colspan="1"><strong>Method</strong></th><th
 colspan="1"><strong>Advantages</strong></th><th colspan="1"><strong>Disadvantages</strong></th></tr><tr><td
 colspan="1"><p>ClickOnce</p></td><td colspan="1"><ul><li 
class="unordered">
Little user interaction<br><br></li><li class="unordered">
Automated updates<br><br></li><li class="unordered">
Little effort for the developer<br><br></li></ul></td><td colspan="1"><ul><li
 class="unordered">
Always deploys as a single solution, cannot be part of a greater whole<br><br></li><li
 class="unordered">
Cannot deploy additional files or registry keys<br><br></li><li 
class="unordered">
Cannot interact with the user to configure the installation <br><br></li><li
 class="unordered">
Cannot brand the installation<br><br></li></ul></td></tr><tr><td 
colspan="1"><p>Windows Installer</p></td><td colspan="1"><ul><li 
class="unordered">
Can deploy additional components and registry settings<br><br></li><li 
class="unordered">
Can interact with the user to configure the installation.<br><br></li><li
 class="unordered">
Custom branding of the installation<br><br></li></ul></td><td 
colspan="1"><ul><li class="unordered">
Requires advanced configuration<br><br></li><li class="unordered">
Higher developer effort required<br><br></li><li class="unordered">
No automated updates<br><br></li></ul></td></tr></tbody></table></div><a
 
id="VSTO3SolutionPart1_DeployingVisualStudioToolsfortheOfficesystem30solutions"></a><h1
 class="heading">Deploying Visual Studio Tools for the Office system 3.0
 solutions</h1><div id="sectionSection2" class="section"><p>Both 
ClickOnce and Windows Installer packages need to perform the same 
rudimentary tasks when installing a VSTO 3.0 Solution.</p><ol 
class="ordered"><li>
Install prerequisite components on the user computer.<br><br></li><li>
Deploy the solution specific components.<br><br></li><li>
For add-ins, create registry entries.<br><br></li><li>
Trust the solution to allow it to execute.<br><br></li></ol><h4 
class="subHeading">Required Prerequisite Components on the Target 
Computer</h4><div class="subSection"><p>To run Visual Studio Tools for 
the Office system 3.0 solutions, the following software must be 
available on the user computer. </p><ul><li class="unordered">
The 2007 Microsoft Office system.<br><br></li><li class="unordered">
The Microsoft .NET Framework, version 3.5.<br>Visual Studio Tools for 
the Office system 3.0 depends on the Microsoft .Net 3.5 Framework. The 
3.5 Framework has new features that support specific requirements of 
Visual Studio Tools for Office.<br><br></li><li class="unordered">
The Microsoft Visual Studio Tools for the Microsoft Office system 
(version 3.0 runtime). <br>Visual Studio Tools for the Office system 3.0
 provides a runtime environment that manages add-ins and document-level 
solutions. For more information about runtime, see <a 
href="http://msdn.microsoft.com/en-us/library/ms178739.aspx">How to: 
Install the Visual Studio Tools for Office Runtime</a>.<br><br></li><li 
class="unordered">
The primary interop assemblies for the 2007 Microsoft Office system.<br>For
 application-level add-ins or document-level solutions for the 2007 
Microsoft Office system, these primary interop assemblies need to be 
available. The 2007 Microsoft Office system installs these assemblies by
 default. However, this does not ensure their availability. <br>Microsoft
 provides a downloadable redistributable package of the primary interop 
assemblies that does not require access to the Office installation 
media. This redistributable package is deployed as part of the overall 
deployment of your Visual Studio Tools for Office solution.<br><br></li><li
 class="unordered">
Optionally, language packs for the Microsoft Visual Studio Tools for the
 Microsoft Office system (version 3.0 runtime).<br><br></li></ul><div 
class="alert"><table><tbody><tr><th><img id="note" 
alt="Cc563937.note(en-us,office.12).gif" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/030c41d9079671d09a62d8e2c1db6973.gif"
 title="Cc563937.note(en-us,office.12).gif" xmlns="" class="cl_IC101471"><strong>Note:
 </strong></th></tr><tr><td>
A primary interop assembly is a unique, vendor-supplied assembly 
containing type definitions (as metadata) of types implemented with COM.
 For more information about primary interop assemblies and Visual Studio
 Tools for the Office system 3.0 see <span class="unresolvedLink">Office
 Primary Interop </span>.<p></p></td></tr></tbody></table><p></p></div></div><h4
 class="subHeading">Solution Specific Components</h4><div 
class="subSection"><p>The installer package must install the following 
components to the user computer.</p><ul><li class="unordered">
The Microsoft Office document, if you create a document-level solution.<br><br></li><li
 class="unordered">
The customization assembly and any assemblies it requires.<br><br></li><li
 class="unordered">
Additional components such as configuration files.<br><br></li><li 
class="unordered">
The application manifest (.manifest).<br><br></li><li class="unordered">
The deployment manifest (.vsto). <br><br></li></ul></div><h4 
class="subHeading">Registry Entries for Add-ins</h4><div 
class="subSection"><p>Add-ins require a set of registry entries for the 
Microsoft Office application to locate the add-in. You should create the
 registry entries as part of the deployment process. For more 
information about registry entries pertaining to a Visual Studio Tools 
for Office add-in, see <a 
href="http://msdn.microsoft.com/en-us/library/bb386106.aspx">Registry 
Entries for Application-Level Add-Ins</a>. When developing an Outlook 
add-in that displays custom form regions you should create additional 
registry keys as part of the installation procedure to allow the form 
regions to be identified. For more information about registry entries 
pertaining to Outlook form regions, see <span class="unresolvedLink">Specifying
 Form Regions in the Windows Registry</span>.</p><p>Document-level 
solutions do not require these registry entries because the 
customization is located by using information inside the Microsoft 
Office document. For more information about the document properties used
 for locating document-level customizations, see <a 
href="http://msdn.microsoft.com/en-us/library/ds87aeyf.aspx">Custom 
Document Properties Overview</a>.</p><p>For the RTM version of Visual 
Studio 2008, there is an issue with the registry when the same name as 
your Visual Studio Tools for Office project is used. See the <a 
href="#VSTO3SolutionPart1_KnownIssues">Known Issues</a> section for more
 details.</p><div class="alert"><table><tbody><tr><th><img id="note" 
alt="Cc563937.note(en-us,office.12).gif" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/030c41d9079671d09a62d8e2c1db6973.gif"
 title="Cc563937.note(en-us,office.12).gif" xmlns="" class="cl_IC101471"><strong>Note:
 </strong></th></tr><tr><td>
An important difference between Microsoft Office 2003 and the 2007 
Microsoft Office system is that the 2007 Microsoft Office system no 
longer supports registering managed add-ins inside the 
HKEY_LOCAL_MACHINE hive.<p></p></td></tr></tbody></table><p></p></div></div><h4
 class="subHeading">Trusting the Visual Studio Tools for Office Solution</h4><div
 class="subSection"><p>Before you allow the customization to execute, a 
solution must be trusted. This trust relationship is based on the signed
 application and deployment manifests. You can either sign the manifests
 with a certificate that identifies a known and trusted publisher, or 
create a trust-relationship at installation time with an inclusion list 
entry. For more information about how to obtain a certificate for 
signing, see <a 
href="http://msdn.microsoft.com/en-us/library/ms172240.aspx">ClickOnce 
Deployment and Authenticode</a>. For more information about using the 
user inclusion list, see <a 
href="http://msdn.microsoft.com/en-us/library/bb608607.aspx">Trusting 
Office Solutions by Using Inclusion Lists (2007 System)</a>.</p><p>If 
neither option is used, a trust prompt is displayed to the user to let 
them decide whether to trust the solution. You can add an inclusion list
 entry with a custom action in your Windows Installer file. For more 
information about enabling the inclusion list, see <a 
href="http://msdn.microsoft.com/en-us/library/bb772070.aspx">How to: 
Configure Inclusion List Security (2007 System)</a>.</p><p>Document-level
 solutions have an extra requirement where the document location must 
also be trusted before the Office application allows the customization 
to load. For more information about security related to document-level 
solutions, see <a 
href="http://msdn.microsoft.com/en-us/library/bb772072.aspx">Granting 
Trust to Documents (2007 System)</a>.</p></div><h4 class="subHeading">Required
 Administrative Rights to Perform an Installation</h4><div 
class="subSection"><p>Visual Studio Tools for the Office system 3.0 
solutions install at a user level, but tasks like installing 
prerequisites or changing custom configurations require administrative 
rights. Other tasks requiring administrative rights include the 
following:</p><ul><li class="unordered">
Deploying primary interop assemblies with your setup project.<br><br></li><li
 class="unordered">
Deploying the Microsoft Visual Studio Tools for the Microsoft Office 
system (version 3.0 runtime) with your setup project.<br><br></li><li 
class="unordered">
Deploying the Microsoft .NET Framework with your setup project.<br><br></li><li
 class="unordered">
Deploying components to folders such as the program files folder.<br><br></li><li
 class="unordered">
Writing registry entries outside of the HKEY_CURRENT_USER hive.<br><br></li></ul></div><h4
 class="subHeading">Mixed Mode Installs</h4><div class="subSection"><p>An
 application-level add-in is only installed for the user executing the 
MSI. Installation for all users is not supported by Visual Studio Tools 
for the Office system 3.0. This is incorporated into the design of the 
2007 Microsoft Office system.</p></div><h4 class="subHeading">Required 
Components for Creating an Installer</h4><div class="subSection"><h4 
class="subHeading">Primary Interop Assemblies</h4><div 
class="subSection"><p>You should deploy the primary interop assemblies 
as part of your Windows Installer file. Visual Studio 2008 installs the 
primary interop assemblies on your development computer, not as a 
redistributable package, but as a set of loose assemblies. While you can
 use these assemblies for development, it is important that you do not 
distribute them.</p><p>You can download the package containing the 
redistributable primary interop assemblies for the 2007 Microsoft Office
 system from the Microsoft Download Center: <span class="unresolvedLink">2007
 Microsoft Office System Update: Redistributable Primary Interop 
Assemblies</span>. After downloading and installing the package on your 
developer computer, you can use the redistributable module and the 
bootstrapper configuration file in the download of this article to have 
the primary interop assemblies appear in the Prerequisites Dialog Box 
inside the Visual Studio 2008 IDE. </p></div><h4 class="subHeading">Language
 Packs</h4><div class="subSection"><p>The Visual Studio Tools for Office
 runtime is capable of displaying administrative messages in various 
languages. To allow messages to be displayed in a different language 
than English, you should download the appropriate language pack and 
deploy it on the target computer along with your solution.</p><p>You can
 only deploy a single language pack for each installer that you build. 
To provide more than one language for your product, you can either 
maintain separate Visual Studio setup projects for each language or 
reconfigure a single setup project for each language before building the
 installer package. </p><p>The following language packs are available 
for download:</p><h3 class="subHeading"></h3><table><tbody><tr><td 
colspan="1"><p><strong>Language</strong></p></td><td colspan="1"><p><strong>Download
 location</strong></p></td></tr><tr><td colspan="1"><p>Japanese</p></td><td
 colspan="1"><p><span class="unresolvedLink">http://go.microsoft.com/fwlink/?LinkId=95147&amp;clcid=0x411</span></p></td></tr></tbody></table><div
 class="alert"><table><tbody><tr><th><img id="note" 
alt="Cc563937.note(en-us,office.12).gif" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/030c41d9079671d09a62d8e2c1db6973.gif"
 title="Cc563937.note(en-us,office.12).gif" xmlns="" class="cl_IC101471"><strong>Note:
 </strong></th></tr><tr><td>
 Visual Studio populates the Prerequisites dialog box by processing a 
specific folder that contains the available prerequisite packages. Each 
package has its own folder in that directory. To read more about 
bootstrapper packages, see <a 
href="http://msdn.microsoft.com/en-us/library/ms165429.aspx">Adding 
Custom Prerequisites</a>. <br>For Visual Studio 2008, the default folder
 for prerequisite packages is <code>%ProgramFiles%\Microsoft 
SDKs\Windows\v6.0A\Bootstrapper\Packages</code><p></p></td></tr></tbody></table><p></p></div></div></div><h4
 class="subHeading">Product Codes and Component IDs</h4><div 
class="subSection"><p>You can use product codes and component IDs to 
check for the presence of certain components on the user computer to 
make sure that the computer meets certain requirements. The product code
 is a unique identifier for the particular product release, represented 
as a string GUID, for example: {12345678-1234-1234-1234-123456789012}. A
 product consists of many components that can be shared across multiple 
products. These components have an ID that is also in the form of a 
GUID. </p><p>Because product codes are not supported for Windows 
Installer file launch conditions, you must use another check, such as a 
component ID or registry entry, to verify the presence of a required 
component. If you are using a component ID to test for the presence of a
 particular product, try to find a component ID that is unique to that 
particular product.</p><p>Table 2 displays relevant product codes and 
component IDs related to Visual Studio Tools for the Office system 3.0. 
Note that the language packs for Visual Studio Tools for Office are now 
separated into language specific packs. Previous versions of Visual 
Studio Tools for Office provided one generic language pack that 
contained all available languages. The following table will be updated 
when new language packs are released.</p><h3 class="subHeading">Table 2.
 Product codes and component IDs of the 2007 Microsoft Office System and
 Visual Studio Tools for Office</h3><table><tbody><tr><th colspan="1"><strong>Package</strong></th><th
 colspan="1"><strong>Product code</strong></th><th colspan="1"><strong>Component
 ID</strong></th></tr><tr><td colspan="1"><p>Visual Studio Tools for the
 Office system (version 3.0 runtime)</p></td><td colspan="1"><p>{8FB53850-246A-3507-8ADE-0060093FFEA6}</p></td><td
 colspan="1"><p>{AF68A0DE-C0CD-43E1-96DD-CBD9726079FD}</p></td></tr><tr><td
 colspan="1"><p>Visual Studio Tools for the Office system 3.0 Language 
Pack – Japanese</p></td><td colspan="1"><p>{A6A9008F-79A3-3118-88B1-0235BDEB718D}</p></td><td
 colspan="1"><p>{A2E56E4D-4E2D-4E2C-8A44-6115CABBB4EF}</p></td></tr><tr><td
 colspan="1"><p>Primary interop assemblies for the 2007 release of 
Office</p></td><td colspan="1"><p>{50120000-1105-0000-0000-0000000FF1CE}</p></td><td
 colspan="1"><p>Use component IDs for specific primary interop 
assemblies listed below.</p></td></tr></tbody></table><p>Besides a 
component ID, you can also determine the presence of the Visual Studio 
Tools for Office runtime by checking for the presence of the following 
registry key. </p><p><strong>HKLM\Software\Microsoft\VSTO Runtime 
Setup\v9.0.21022</strong></p><p>When Visual Studio Tools for Office is 
installed, this key has a value named <strong>Install</strong> with a <strong>DWORD</strong>
 value of 1. Later updates to the runtime are located by the Update 
value found under this registry key. The Update value is not present on 
the RTM installation of Visual Studio Tools for the Office system 3.0.</p><p>Table
 3 lists the component IDs of the primary interop assemblies. You can 
use these values to check for the presence of specific interop 
assemblies during the installation process. The Office Shared primary 
interop assembly is used by all Visual Studio Tools for Office 
solutions.</p><h3 class="subHeading">Table 3. Component IDs of the 
Redistributable Primary Interop Assemblies for the Microsoft Office 
System</h3><table><tbody><tr><th colspan="1"><strong>Primary interop 
assembly</strong></th><th colspan="1"><strong>Office 2007 component ID</strong></th></tr><tr><td
 colspan="1"><p>Excel</p></td><td colspan="1"><p>{1ABEAF09-435F-47D6-9FEB-0AD05D4EF3EA}</p></td></tr><tr><td
 colspan="1"><p>InfoPath</p></td><td colspan="1"><p>{F1B5AE30-CB00-4DCF-978B-07D33B034ADB}</p></td></tr><tr><td
 colspan="1"><p>Outlook </p></td><td colspan="1"><p>{ED569DB3-58C4-4463-971F-4AAABB6440BD}</p></td></tr><tr><td
 colspan="1"><p>PowerPoint</p></td><td colspan="1"><p>{04E73476-518E-4B6A-8E10-021A00078847}</p></td></tr><tr><td
 colspan="1"><p>Visio</p></td><td colspan="1"><p>{C1F1028F-D91A-43E8-A117-4F7CAFD7A041}</p></td></tr><tr><td
 colspan="1"><p>Word</p></td><td colspan="1"><p>{816D4DFD-FF7B-4C16-8943-EEB07DF989CB}</p></td></tr><tr><td
 colspan="1"><p>Microsoft Forms 2.0</p></td><td colspan="1"><p>{835AC3CE-E36B-4D65-B50F-2863A682ABEE}</p></td></tr><tr><td
 colspan="1"><p>Microsoft Graph </p></td><td colspan="1"><p>{580CB155-841D-4D48-9F59-866A035C2241}</p></td></tr><tr><td
 colspan="1"><p>Smart Tag</p></td><td colspan="1"><p>{00B41853-4377-4AD8-AD44-8404E0D331EC}</p></td></tr><tr><td
 colspan="1"><p>Office Shared</p></td><td colspan="1"><p>{FAB10E66-B22C-4274-8647-7CA1BA5EF30F}</p></td></tr><tr><td
 colspan="1"><p>Project</p></td><td colspan="1"><p>{957A4EC0-E67B-4E86-A383-6AF7270B216A}</p></td></tr></tbody></table></div></div><a
 id="VSTO3SolutionPart1_DownloadSamplesProvidedwiththisArticle"></a><h1 
class="heading">Download Samples Provided with this Article</h1><div 
id="sectionSection3" class="section"><p>The walkthroughs provided in 
this article use various sample files contained in the download. The 
download contains the source code for the following components:</p><ul><li
 class="unordered">
All sample projects created in this article.<br><br></li><li 
class="unordered">
Bootstrapper configuration files for the Redistributable Primary Interop
 Assemblies for the 2007 Microsoft Office system.<br><br></li><li 
class="unordered">
Custom action classes for the Setup projects used to deploy the Visual 
Studio Tools for Office solution.<br><br></li></ul><p>By default, these 
files are installed into the following folder:</p><p><code>%ProgramFiles%\Microsoft
 Visual Studio Tools for the Office system 3.0 Resources\Windows 
Installer Sample\</code></p><p>This article refers to this installation 
folder as {SamplesDir}.</p><p><strong>Download:</strong><span 
class="unresolvedLink">http://code.msdn.microsoft.com/VSTO3MSI</span></p></div><a
 id="VSTO3SolutionPart1_PreparingyourDevelopmentComputer"></a><h1 
class="heading">Preparing your Development Computer</h1><div 
id="sectionSection4" class="section"><p>Before creating a Windows 
Installer package, you first need to prepare your development computer.</p>


To download and install the redistributable Primary Interop Assemblies
<ol class="ordered"><li><p>Download the installer for the <span 
class="unresolvedLink">Redistributable Primary Interop Assemblies for 
the 2007 Microsoft Office System</span>.</p></li><li><p>Run the 
installer.</p></li><li><p>Accept the Microsoft Software License Terms. 
This gives you permission to package the primary interop assemblies as 
part of your installer.</p></li><li><p>In <strong>Windows Explorer</strong>,
 open the folder where the installer extracted the files. Copy <strong>O2007PIA.msi</strong>
 to the directory <strong>{SamplesDir}\packages\Office2007PIA</strong>.</p></li></ol><p>If
 you intend to provide a different language other than English you can 
download and install the appropriate language packs for the Visual 
Studio Tools for Office runtime and bootstrapper package. </p>


To download and install language packs
<ol class="ordered"><li><p>Download the language pack for the language 
that you require. </p><p>For Japanese, download from <span 
class="unresolvedLink">http://go.microsoft.com/fwlink/?LinkId=95147&amp;clcid=0x411</span></p></li><li><p>Copy
 the downloaded file to the language specific subfolder of <strong>{SamplesDir}\packages\VSTOR30</strong>.</p></li><li><p>For
 Japanese, use the <strong>ja</strong> subfolder.</p></li></ol><p>The 
bootstrapper configuration files use the <strong>ComponentCheck.exe</strong>
 tool for the primary interop assemblies to verify the presence of 
Microsoft Office on the user computer. To compile it, you need to have a
 C++ compiler available, like the one provided with Visual Studio 2008.</p><div
 class="alert"><table><tbody><tr><th><img id="note" 
alt="Cc563937.note(en-us,office.12).gif" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/030c41d9079671d09a62d8e2c1db6973.gif"
 title="Cc563937.note(en-us,office.12).gif" xmlns="" class="cl_IC101471"><strong>Note:
 </strong></th></tr><tr><td>
Because the prerequisite packages are executed before the installation 
begins, you cannot be certain that the Microsoft .NET Framework is 
available on the user computer. For this reason, the ComponentCheck.exe 
tool is written in C++ and compiles to native code, so that the 
Microsoft .NET runtime environment is not needed at this point during 
the installation. It is also not feasible to distribute the 
ComponentCheck.exe tool as part of Visual Studio Tools for Office 
because this environment might not be installed on the user computer.<p></p></td></tr></tbody></table><p></p></div>


To prepare the Office ComponentCheck
<ol class="ordered"><li><p>Open a Visual Studio 2008 Command Prompt.</p></li><li><p>In
 the command prompt window, change the directory to <strong>{SamplesDir}\projects\ComponentCheck</strong>.</p></li><li><p>Compile
 the component checker by typing the following command</p><div 
class="LW_CodeSnippetContainer" xmlns=""><a name="CodeSpippet0"></a><div
 class="LW_CodeSnippetContainerCodeCollection"><div 
class="LW_CodeSnippetToolBar"><div class="LW_CodeSnippetToolBarText" 
style=""><a title="Copy to clipboard." 
href="javascript:CodeSnippet_CopyCode('CodeSnippetContainerCode0');">Copy</a></div></div><div
 id="CodeSnippetContainerCode0" class="LW_CodeSnippetContainerCode"><div
 style="color: Black;"><pre>cl.exe /Oxs /MT /GS ComponentCheck.cpp advapi32.lib
</pre></div></div></div></div></li><li><p>Close the command prompt 
window.</p></li><li><p>Using <strong>Windows Explorer</strong>, copy the
 executable file <strong>ComponentCheck.exe</strong> from {<strong>SamplesDir}\projects\ComponentCheck</strong>
 into the <strong>{SamplesDir}\packages\Office2007PIA</strong> folder.</p></li></ol><p>The
 following procedure shows how you can move the bootstrapper packages to
 the bootstrapper directory, so that you can select them from the 
Prerequisites Dialog Box in the Visual Studio 2008 IDE.</p>


To copy the packages into the bootstrapper directory
<ol class="ordered"><li><p>Determine where your bootstrapper package 
directory is located. For an overview of directories that Visual Studio 
searches for bootstrapper packages, see <a 
href="http://msdn.microsoft.com/en-us/library/ms165429.aspx">Adding 
Custom Prerequisites</a>. For Visual Studio 2008, the default folder for
 prerequisite packages is<br><strong>%ProgramFiles%\Microsoft 
SDKs\Windows\v6.0A\Bootstrapper\Packages.</strong></p></li><li><p>Copy 
the contents from <strong>{SamplesDir}\packages</strong> into the 
bootstrapper packages directory.</p></li></ol></div><a 
id="VSTO3SolutionPart1_CreatingtheAddinProject"></a><h1 class="heading">Creating
 the Add-in Project</h1><div id="sectionSection5" class="section"><p>The
 first step is to create a sample add-in project. In this walkthrough, 
you create a basic Excel add-in using and Visual Studio 2008.</p><p>The 
ExcelAddIn is a simple add-in for Microsoft Office Excel 2007 that 
displays a custom message when the add-in is loaded. The add-in is kept 
as simple as possible to allow focus on the general concepts of the 
deployment. </p>


To create the ExcelAddIn project
<ol class="ordered"><li><p>Open Microsoft Visual Studio 2008.</p></li><li><p>On
 the <strong>File</strong> menu, expand <strong>New</strong> and click <strong>Project</strong>
 to create a new Visual Studio project.</p></li><li><p>In the <strong>New
 Project</strong> dialog box, in the <strong>Project types</strong> 
pane, expand <strong>Visual Basic</strong> or <strong>Visual C#</strong>,
 expand <strong>Office</strong>, and then select <strong>2007</strong>. </p></li><li><p>In
 the <strong>Templates</strong> pane, select <strong>Excel 2007 Add-in</strong>.</p></li><li><p>In
 the <strong>Name</strong> box, type <strong>ExcelAddIn</strong>.</p></li><li><p>In
 the <strong>Solution name</strong> box, type <strong>VSTO v3 Deployment
 Demo</strong>.</p></li><li><p>Select <strong>Create Directory for 
Solution</strong>, and click <strong>OK</strong> to create the new Excel
 2007 add-in. The Solution Explorer displays the opened solution, and 
opens the main code file.</p><br><br><strong>Figure 1. Solution Explorer
 (C#)</strong><br><br><img id="13891583-a656-4185-baa7-68ba400064e2" 
alt="Solution Explorer" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/IC42452.jpg"
 title="Solution Explorer" xmlns=""></li></ol><p>Visual Studio provides 
two build configurations out of the box. You should make sure only to 
distribute release builds because these assemblies are optimized. Be 
aware that release builds might hinder debugging of your solution 
because of optimizations in the execution order.</p><p>For more 
information about Visual Studio and build configurations, see <span 
class="unresolvedLink">Build Configurations</span>.</p>


To set the build configuration to release
<ol class="ordered"><li><p>In the <strong>Solution Explorer</strong>, 
right-click <strong>Solution ‘VSTO v3 Deployment Demo’ (1 project)</strong>
 and click <strong>Configuration Manager</strong> to show the build 
configuration manager for the Visual Studio solution.</p><p><strong>Note</strong>&nbsp;&nbsp;&nbsp;
 Your computer might show different names or locations for some of the 
Visual Studio user interface elements in the following procedures. The 
Visual Studio edition that you have and the settings that you use 
determine these elements. For more information, see <a 
href="http://msdn.microsoft.com/en-us/library/zbhkx167.aspx">Visual 
Studio Settings</a>.</p></li><li><p>In the <strong>Configuration Manager</strong>
 dialog box, for <strong>Active Solution Configuration</strong>, select <strong>Release</strong>.</p><br><br><strong>Figure
 2. Configuration Manager dialog box</strong><br><br><img 
id="11a492fe-e240-4cdd-9b53-b6aae7224b09" alt="Configuration Manager 
dialog box" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/IC101992.jpg"
 title="Configuration Manager dialog box" xmlns=""></li><li><p>Click <strong>Close</strong>
 to close the dialog box.</p></li></ol><p>The last step for the add-in 
project is to add some code to verify that the add-in is running 
correctly. </p>


To add code to the ExcelAddIn project
<ol class="ordered"><li><p>If the code file for the <strong>ThisAddIn</strong>
 class is not currently open, in the <strong>Solution Explorer</strong>,
 right-click the <strong>ThisAddIn.vb</strong> or <strong>ThisAddIn.cs</strong>
 file and click <strong>View code</strong> to open the main code file 
for the ExcelAddIn add-in.</p></li><li><p>In the code editor, locate the
 <strong>ThisAddIn_StartUp</strong> method. Add a call to the <strong>System.Windows.Forms.MessageBox.Show</strong>
 method to display a custom message when the add-in starts.</p><div 
class="LW_CodeSnippetContainer" xmlns=""><a name="CodeSpippet1"></a><div
 class="LW_CodeSnippetContainerTabs"><div 
class="LW_CodeSnippetContainerTabLeft"><img 
class="cl_lw_codesnippet_lt_tab" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/0988b66c1e448ee567fca35fa16b4f24.png"></div><div
 class="LW_CodeSnippetContainerTabFirst"><a 
href="javascript:%20CodeSnippet_SetLanguage('Visual%20Basic');" 
class="LW_CodeSnippetContainerTabLinkBold">VB</a></div><div 
class="LW_CodeSnippetContainerTabActive"><a 
class="LW_CodeSnippetContainerTabLinkNormal">C#</a></div><div 
class="LW_CodeSnippetContainerTab"><a 
href="javascript:%20CodeSnippet_SetLanguage('Visual%20C++');" 
class="LW_CodeSnippetContainerTabLinkNormal">C++</a></div><div 
class="LW_CodeSnippetContainerTab"><a 
href="javascript:%20CodeSnippet_SetLanguage('F#');" 
class="LW_CodeSnippetContainerTabLinkNormal">F#</a></div><div 
class="LW_CodeSnippetContainerTabLast"><a 
href="javascript:%20CodeSnippet_SetLanguage('JScript');" 
class="LW_CodeSnippetContainerTabLinkNormal">JScript</a></div><div 
class="LW_CodeSnippetContainerTabRight"><img 
class="cl_lw_codesnippet_rt_tab" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/0988b66c1e448ee567fca35fa16b4f24.png"></div></div><div
 class="LW_CodeSnippetContainerCodeCollection"><div 
class="LW_CodeSnippetToolBar"><div class="LW_CodeSnippetToolBarText" 
style=""><a title="Copy to clipboard." 
href="javascript:CodeSnippet_CopyCode('CodeSnippetContainerCode1');">Copy</a></div></div><div
 id="CodeSnippetContainerCode1" class="LW_CodeSnippetContainerCode"><div
 style="color: Black;"><pre>This language is not supported or no code example is available.
</pre></div></div></div></div><p></p><div 
class="LW_CodeSnippetContainer" xmlns=""><a name="CodeSpippet2"></a><div
 class="LW_CodeSnippetContainerTabs"><div 
class="LW_CodeSnippetContainerTabLeft"><img 
class="cl_lw_codesnippet_lt_tab" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/0988b66c1e448ee567fca35fa16b4f24.png"></div><div
 class="LW_CodeSnippetContainerTabFirst"><a 
href="javascript:%20CodeSnippet_SetLanguage('Visual%20Basic');" 
class="LW_CodeSnippetContainerTabLinkNormal">VB</a></div><div 
class="LW_CodeSnippetContainerTabActive"><a 
class="LW_CodeSnippetContainerTabLinkBold">C#</a></div><div 
class="LW_CodeSnippetContainerTab"><a 
href="javascript:%20CodeSnippet_SetLanguage('Visual%20C++');" 
class="LW_CodeSnippetContainerTabLinkNormal">C++</a></div><div 
class="LW_CodeSnippetContainerTab"><a 
href="javascript:%20CodeSnippet_SetLanguage('F#');" 
class="LW_CodeSnippetContainerTabLinkNormal">F#</a></div><div 
class="LW_CodeSnippetContainerTabLast"><a 
href="javascript:%20CodeSnippet_SetLanguage('JScript');" 
class="LW_CodeSnippetContainerTabLinkNormal">JScript</a></div><div 
class="LW_CodeSnippetContainerTabRight"><img 
class="cl_lw_codesnippet_rt_tab" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/0988b66c1e448ee567fca35fa16b4f24.png"></div></div><div
 class="LW_CodeSnippetContainerCodeCollection"><div 
class="LW_CodeSnippetToolBar"><div class="LW_CodeSnippetToolBarText" 
style=""><a title="Copy to clipboard." 
href="javascript:CodeSnippet_CopyCode('CodeSnippetContainerCode2');">Copy</a></div></div><div
 id="CodeSnippetContainerCode2" class="LW_CodeSnippetContainerCode"><div
 style="color: Black;"><pre><span style="color: Blue;">public</span> <span style="color: Blue;">partial</span> <span style="color: Blue;">class</span> ThisAddIn
{    <span style="color: Blue;">private</span> <span style="color: Blue;">void</span> ThisAddIn_Startup(<span style="color: Blue;">object</span> sender, System.EventArgs e)    {        System.Windows.Forms.MessageBox.Show(<span style="color: rgb(163, 21, 21);">"Hello World"</span>);    }}
</pre></div></div></div></div></li></ol><p>Before you create the setup 
project for the ExcelAddIn add-in, first build the project so the 
project output is available for the setup project. Building the add-in 
generates the deployment and application manifests required for the 
deployment and installation of the add-in.</p>


To build the ExcelAddIn project
<ol class="ordered"><li><p>On the <strong>Build</strong> menu, select <strong>Build
 Solution</strong> to compile the modified add-in. Make sure that there 
are no compilation errors. </p><br><br><strong>Figure 3. Solution 
Explorer for ExcelAddIn</strong><br><br><img 
id="adceab9f-89a8-4869-bf6a-24094aef3198" alt="Solution Explorer for 
ExcelAddIn" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/IC931.jpg"
 title="Solution Explorer for ExcelAddIn" xmlns=""></li><li><p><strong>Note</strong>&nbsp;&nbsp;&nbsp;
 Building the ExcelAddIn project generates a new project item called 
ExcelAddIn_TemporaryKey.pfx. This file contains the certificate used to 
sign the deployment manifest in PKCS #12 format. The Visual Studio Tools
 for Office environment automatically adds a temporary certificate to 
sign the solution. You should never use this certificate for actual 
deployment of a Visual Studio Tools for Office solution. Request a 
certificate from a certificate authority trusted by both you and the 
user or request a certificate from one of the well-known commercial 
certificate authorities.</p></li></ol></div><a 
id="VSTO3SolutionPart1_CreatingaBasicInstaller"></a><h1 class="heading">Creating
 a Basic Installer</h1><div id="sectionSection6" class="section"><p>Visual
 Studio 2008 provides a built-in project type for creating Windows 
Installer packages. With some added configuration, this project type is 
used to deploy a Visual Studio Tools for Office solution. To create an 
installer for the ExcelAddIn customization, perform the following tasks.</p><ul><li
 class="unordered">
Configure prerequisite components.<br><br></li><li class="unordered">
Verify that the required prerequisite components are available. The user
 might not execute the bootstrapper (setup.exe), but execute the MSI 
directly instead. This circumvents the installation of prerequisite 
components.<br><br></li><li class="unordered">
Add the components of the ExcelAddIn.<br><br></li><li class="unordered">
Configure registry entries for the add-in<br><br></li></ul><p>When a 
Visual Studio Tools for Office solution is locally installed using 
Windows Installer there are differences in the behavior of the Visual 
Studio Tools for Office runtime compared to solutions deployed using 
ClickOnce. First of all, the security is verified each time the solution
 is loaded. Additionally, the solution is not added to the ClickOnce 
cache, which means there are no automatic updates of the add-in. 
Deploying updates to your solution requires redistribution and 
installation of a new Windows Installer package.</p><p>You must specify 
that the solution is locally installed. This is indicated using the 
deployment manifest property. This property is defined in the Windows 
registry for add-ins and inside the document properties for 
document-level solutions. The manifest property is the location with the
 postfix |<strong>vstolocal</strong> to indicate the local install.</p><p>Start
 by creating the setup project. This project contains the configuration 
for the Windows Installer package. Part of the configuration is 
performed using built-in features. Additional tasks are performed using 
custom actions.</p>


To create the ExcelAddInSetup project
<ol class="ordered"><li><p>On the <strong>File</strong> menu, expand <strong>Add</strong>
 and click <strong>New Project</strong> to add a new project to the VSTO
 v3 Deployment Demo solution.</p></li><li><p>In the <strong>Add New 
Project</strong> dialog box, in <strong>the Project types</strong> pane,
 expand <strong>Other Project Types</strong> and then select <strong>Setup
 and Deployment</strong>. </p></li><li><p>In the <strong>Templates</strong>
 pane, select <strong>Setup Project</strong> from the <strong>Visual 
Studio installed</strong> templates group.</p></li><li><p>In the <strong>Name</strong>
 box, type <strong>ExcelAddInSetup</strong>.</p></li><li><p>Ensure that 
the folder identified by the <strong>Location</strong> box is inside the
 VSTO v3 Deployment Demo folder created for the solution, and click <strong>Open</strong>
 to create the new setup project. Visual Studio opens the File Explorer 
for the new setup project. This explorer allows you to add files to the 
setup project from locations such as the projects inside your solution 
or loose files from your file-system.</p><br><br><strong>Figure 4. 
Solution Explorer for ExcelAddInSetup</strong><br><br><img 
id="a6f6b724-0925-4d8d-81f9-8381d3a7df39" alt="Solution Explorer for 
ExcelAddInSetup" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/IC153882.jpg"
 title="Solution Explorer for ExcelAddInSetup" xmlns=""></li></ol><p>The
 setup project needs to deploy the ExcelAddIn DLL. You can configure the
 setup project for this task by adding the ExcelAddIn project output to 
the setup project.</p>


To add the ExcelAddIn project output
<ol class="ordered"><li><p>In the <strong>Solution Explorer</strong>, 
right-click <strong>ExcelAddInSetup</strong>, click<strong> Add</strong>
 and then <strong>Project</strong><strong>Output</strong>.</p></li><li><p>In
 the <strong>Add Project Output Group</strong> dialog box, confirm that 
the <strong>ExcelAddIn</strong> project is selected, and the <strong>Primary</strong><strong>Output</strong>
 option is selected. </p></li><li><p>Click <strong>Open </strong>to add 
the project output to the setup project. </p><br><br><strong>Figure 5. 
ExcelAddInSetup Dependencies</strong><br><br><img 
id="ee6aea6d-191b-49e3-bd61-d7f7cc866a51" alt="ExcelAddInSetup 
Dependencies" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/IC105663.jpg"
 title="ExcelAddInSetup Dependencies" xmlns=""></li></ol><p>The setup 
project needs to deploy the deployment manifest and application 
manifest. You can add these two files to the setup project as 
stand-alone files from the output folder of the ExcelAddIn project.</p>


To add the deployment and application manifests
<ol class="ordered"><li><p>In the <strong>Solution Explorer</strong>, 
right-click <strong>ExcelAddInSetup</strong>, click <strong>Add</strong>,
 and click <strong>File</strong>.</p></li><li><p>In the <strong>Add 
Files</strong> dialog box, navigate to the <strong>ExcelAddIn</strong> 
output directory. Usually the output directory is the <strong>bin\release</strong>
 subfolder of the project root directory, depending on the selected 
build configuration. </p></li><li><p>Select the <strong>ExcelAddIn.vsto</strong>
 and <strong>ExcelAddIn.dll.manifest</strong> files and click <strong>OK</strong>
 to add these two files to the setup project.</p><br><br><strong>Figure 
6. ExcelAddIn Manifests</strong><br><br><img 
id="e84a213b-0cff-4b1a-8c28-064456790e32" alt="ExcelAddInManifests" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/IC95000.jpg"
 title="ExcelAddInManifests" xmlns=""></li></ol><p>The downside of 
adding loose files to a setup project is that you reference the default 
output folder of the Release build configuration explicitly. When you 
change the build configuration back to Debug, the setup project still 
references the files from this folder. Because you should only 
distribute release builds this is acceptable. Alternatively, you can 
configure the Debug and Release build configuration to output their 
files to the same directory.</p><p>Referencing the ExcelAddIn includes 
all the components that ExcelAddIn requires. These components must be 
excluded and deployed using prerequisite packages to allow them to be 
registered correctly. Also, the Software License Terms must be displayed
 and accepted before the installation begins.</p>


To exclude the ExcelAddIn project dependencies
<ol class="ordered"><li><p>In the <strong>Solution Explorer</strong>, in
 the <strong>ExcelAddInSetup</strong> node, select all dependency items 
beneath the <strong>Detected Dependencies</strong> item except for <strong>Microsoft
 .NET Framework</strong>.</p></li><li><p>Right-click the group and 
select <strong>Properties</strong>. </p></li><li><p>In the <strong>Properties</strong>
 window, change the <strong>Exclude</strong> property to <strong>True</strong>
 to exclude the dependent assemblies from the setup project. </p><br><br><strong>Figure
 7. Excluding Dependencies</strong><br><br><img 
id="143a06ad-1c18-4299-9218-e9626b90ebf5" alt="Excluding Dependencies" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/IC133070.jpg"
 title="Excluding Dependencies" xmlns=""></li></ol><p>Your Windows 
Installer package should install the prerequisite components. The setup 
project can include and install the redistributables provided by the 
component vendors, a process called <strong>bootstrapping</strong>. For 
the ExcelAddIn, the following prerequisites must be installed before the
 add-in can run correctly.</p><ul><li class="unordered">
Microsoft .NET Framework 3.5<br><br></li><li class="unordered">
Microsoft Visual Studio Tools for the Microsoft Office system (version 
3.0 Runtime) <br><br></li><li class="unordered">
Redistributable Primary Interop Assemblies for the 2007 Microsoft Office
 system. <br><br></li><li class="unordered">
Windows Installer 3.1<br><br></li></ul><p>For the Redistributable 
Primary Interop Assemblies for the 2007 Microsoft Office system to 
appear in Visual Studio 2008, you must perform the steps detailed in <a 
href="#VSTO3SolutionPart1_PreparingyourDevelopmentComputer">Preparing 
your Development Computer</a>.</p>


To configure dependent components as prerequisites
<ol class="ordered"><li><p>In the <strong>Solution Explorer</strong>, 
right-click the <strong>ExcelAddInSetup</strong> project and select <strong>Properties</strong>.</p></li><li><p>The
 <strong>ExcelAddInSetup Property Pages</strong> dialog box appears.</p></li><li><p>Click
 <strong>Prerequisites</strong>.</p></li><li><p>In the <strong>Prerequisites</strong>
 dialog box, perform the following tasks.</p><ol class="ordered"><li>
Select <strong>Create setup program to install prerequisite components</strong>.
 This creates the setup.exe bootstrapper together with the MSI file.<br><br></li><li>
In the <strong>Choose prerequisites to install </strong>list, select the
 following:<br><br><strong>Windows Installer 3.1</strong><br><br><strong>.NET
 Framework 3.5</strong><br><br><strong>2007 Microsoft Office Primary 
Interop Assemblies</strong><br><br><strong>Visual Studio Tools for the 
Office system 3.0 Runtime</strong><br><br></li><li>
For <strong>Specify the install location for prerequisites</strong>, 
select <strong>Download prerequisites from the same location as my 
application</strong>.<br><br></li><li>
Click <strong>OK</strong> to close the Prerequisites dialog box<br><br></li><li>
Click <strong>OK</strong> to close the property pages of 
ExcelAddInSetup.<br><br></li></ol><div class="alert"><table><tbody><tr><th><img
 id="note" alt="Cc563937.note(en-us,office.12).gif" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/030c41d9079671d09a62d8e2c1db6973.gif"
 title="Cc563937.note(en-us,office.12).gif" xmlns="" class="cl_IC101471"><strong>Note:
 </strong></th></tr><tr><td>
You cannot download the Redistributable Primary Interop Assemblies 
package for the 2007 Microsoft Office system from the internet as part 
of the MSI installation. Doing so skips the Microsoft Software License 
Terms acceptance step that allows you to redistribute the package. Your 
installation options are to pre-install the PIA package (and exclude the
 package in the setup), download from the same location as the setup, or
 download from a separate network location. This procedure uses the 
second option.<p></p></td></tr></tbody></table><p></p></div><br><br><strong>Figure
 8. Prerequisites Dialog Box</strong><br><br><img 
id="ab44f10d-f429-4216-a924-174f7e06c6ad" alt="Prerequisites Dialog Box"
 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/IC6897.jpg"
 title="Prerequisites Dialog Box" xmlns=""><div class="alert"><table><tbody><tr><th><img
 id="note" alt="Cc563937.note(en-us,office.12).gif" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/030c41d9079671d09a62d8e2c1db6973.gif"
 title="Cc563937.note(en-us,office.12).gif" xmlns="" class="cl_IC101471"><strong>Note:
 </strong></th></tr><tr><td>
 The configured prerequisite packages in your Visual Studio 2008 Setup 
Project are dependent on the selected build configuration. You must 
select the right prerequisite components for each build configuration 
that you use. The samples and procedures only use the default <strong>Release</strong>
 build configuration.<p></p></td></tr></tbody></table><p></p></div></li></ol><p>Microsoft
 Office locates the application-level add-in by using registry keys in 
the HKEY_CURRENT_USER hive. The Visual Studio setup project is capable 
of configuring the required registry keys.</p><div class="alert"><table><tbody><tr><th><img
 id="note" alt="Cc563937.note(en-us,office.12).gif" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/030c41d9079671d09a62d8e2c1db6973.gif"
 title="Cc563937.note(en-us,office.12).gif" xmlns="" class="cl_IC101471"><strong>Note:
 </strong></th></tr><tr><td>
 The keys live in a user specific key hive, which makes the add-in 
available only to the user running the setup.<p></p></td></tr></tbody></table><p></p></div><p>For
 more information about registry keys, see <a 
href="http://msdn.microsoft.com/en-us/library/bb386106.aspx">Registry 
Entries for Application-Level Add-Ins</a>.</p>


To configure the registry
<ol class="ordered"><li><p>In the <strong>Solution Explorer</strong>, 
right-click <strong>ExcelAddInSetup</strong>.</p></li><li><p>Expand <strong>View</strong>.</p></li><li><p>Click
 <strong>Registry</strong> to open the registry editor window.</p></li><li><p>In
 the <strong>Registry(ExcelAddInSetup)</strong> editor, expand <strong>HKEY_LOCAL_MACHINE</strong>
 and then <strong>Software</strong>.</p></li><li><p>Delete the <strong>[Manufacturer]</strong>
 key found under <strong>HKEY_LOCAL_MACHINE\Software</strong>. This key 
is automatically added when the setup project is created and is not used
 by the add-in.</p></li><li><p>Expand <strong>HKEY_CURRENT_USER</strong>
 and then <strong>Software</strong>.</p></li><li><p>Delete the <strong>[Manufacturer]</strong>
 key found under <strong>HKEY_CURRENT_USER\Software</strong>. This key 
is also added automatically and isn’t used by the add-in.</p></li><li><p>Right-click
 the <strong>Software</strong> key under <strong>HKEY_CURRENT_USER</strong>,
 select <strong>New</strong> and then <strong>Key</strong>. Use the text
 <strong>Microsoft</strong> for the name of the new key.</p></li><li><p>Use
 a similar process to create the entire key hierarchy required for the 
add-in registration. The following key hierarchy is used for the 
ExcelAddIn add-in. </p><div class="LW_CodeSnippetContainer" xmlns=""><a 
name="CodeSpippet3"></a><div 
class="LW_CodeSnippetContainerCodeCollection"><div 
class="LW_CodeSnippetToolBar"><div class="LW_CodeSnippetToolBarText" 
style=""><a title="Copy to clipboard." 
href="javascript:CodeSnippet_CopyCode('CodeSnippetContainerCode3');">Copy</a></div></div><div
 id="CodeSnippetContainerCode3" class="LW_CodeSnippetContainerCode"><div
 style="color: Black;"><pre>HKEY_CURRENT_USER\Software\Microsoft\Office\Excel\Addins\SampleCompany.ExcelAddIn
</pre></div></div></div></div><div class="alert"><table><tbody><tr><th><img
 id="note" alt="Cc563937.note(en-us,office.12).gif" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/030c41d9079671d09a62d8e2c1db6973.gif"
 title="Cc563937.note(en-us,office.12).gif" xmlns="" class="cl_IC101471"><strong>Note:
 </strong></th></tr><tr><td>
 The name of your company is used as a prefix for the name of the 
add-in. This provide uniqueness for this part of the registry key and 
allows add-ins with similar names originating from different suppliers 
to work without accidentally overwriting each other's registration keys.
 This does not provide full uniqueness but should suffice to prevent 
collisions.<p></p></td></tr></tbody></table><p></p></div></li><li><p>Right-click
 the <strong>SampleCompany.ExcelAddIn</strong> key, select <strong>New</strong>
 and click <strong>String value</strong>. Use the text <strong>Description</strong>
 for the new value.</p></li><li><p>Use this step to add three more 
values. Use the following names and data type.</p><ol class="ordered"><li><strong>FriendlyName</strong>
 of type <strong>String</strong><br><br></li><li><strong>LoadBehavior</strong>
 of type <strong>DWORD</strong><br><br></li><li><strong>Manifest</strong>
 of type <strong>String</strong><br><br></li></ol></li><li><p>Right-click
 the <strong>Description</strong> value in the registry editor and click
 <strong>Properties Window</strong>. In the <strong>Properties Window</strong>
 enter <strong>Excel Demo AddIn</strong> for the <strong>Value</strong> 
property.</p></li><li><p>Select the <strong>FriendlyName</strong> key in
 the registry editor. In the <strong>Properties Window</strong>, change 
the <strong>Value</strong> property to <strong>Excel Demo AddIn</strong>.</p></li><li><p>Select
 the <strong>LoadBehavior</strong> key in the registry editor. In the 
Properties Window, change the <strong>Value</strong> property to <strong>3.</strong></p><p>The
 value 3 for the LoadBehavior value indicates that the add-in should be 
loaded at startup of the host application.</p></li><li><p>Select the <strong>Manifest</strong>
 key in the registry editor. In the <strong>Properties Window</strong>, 
change the <strong>Value</strong> property to <strong>[TARGETDIR]ExcelAddIn.vsto|vstolocal</strong></p><br><br><strong>Figure
 9. Registry Keys setup</strong><br><br><img 
id="bc0fe48d-d757-42e2-95cd-3d25e030060a" alt="Registry Keys setup" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/IC128468.jpg"
 title="Registry Keys setup" xmlns=""><div class="alert"><table><tbody><tr><th><img
 id="note" alt="Cc563937.note(en-us,office.12).gif" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/030c41d9079671d09a62d8e2c1db6973.gif"
 title="Cc563937.note(en-us,office.12).gif" xmlns="" class="cl_IC101471"><strong>Note:
 </strong></th></tr><tr><td>
 There are a few interesting notes on how the Visual Studio Tools for 
Office locates the add-in. Visual Studio Tools for Office searches for 
the deployment manifest indicated by the Manifest value. The [TARGETDIR]
 part is a macro that the Windows Installer expands to the actual folder
 where the add-in is installed. This macro expands to include the 
trailing \ character, so the filename of the deployment manifest is 
appended as ExcelAddIn.vsto without the \ character. Finally there is 
the use of the <strong>vstolocal</strong> postfix. This tells the Visual
 Studio Tools for Office runtime that the add-in should load from the 
location indicated by the Manifest value, and not loaded into the 
ClickOnce cache. Removing this postfix will cause the runtime to copy 
the customization into the ClickOnce cache.<p></p></td></tr></tbody></table><p></p></div></li><li><p>In
 the <strong>Registry (ExcelAddInSetup)</strong> editor, right-click the
 <strong>SampleCompany.ExcelAddIn</strong> key and click <strong>Properties
 Windows</strong>.</p></li><li><p>In the <strong>Properties</strong> 
window, set the value of <strong>DeleteAtUninstall</strong> to <strong>True</strong>
 to ensure that the registry keys are deleted when the Visual Studio 
Tools for Office add-in is uninstalled.</p><br><br><strong>Figure 10. 
Registry Keys Properties Window</strong><br><br><img 
id="2143398f-309b-4251-b84a-e30aa2ccd410" alt="Registry Keys Properties 
Window" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/IC41433.jpg"
 title="Registry Keys Properties Window" xmlns=""></li></ol><div 
class="alert"><table><tbody><tr><th><img id="Warning" 
alt="Cc563937.Warning(en-us,office.12).gif" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/IC174466.gif"
 title="Cc563937.Warning(en-us,office.12).gif" xmlns=""><strong>Warning:
 </strong></th></tr><tr><td>
 You should be very careful with the Registry Editor in Visual Studio. 
For example, if you accidentally set DeleteAtUninstall for the wrong 
key, you might delete an active part of the registry, leaving the user 
computer in an inconsistent, or even worse, broken state.<p></p></td></tr></tbody></table><p></p></div><p>When
 the user does not execute the setup bootstrapper (setup.exe), it is 
possible that the MSI package will install on a computer without the 
required prerequisites. Launch conditions are used to prevent the 
ExcelAddIn from installing on computers without installed prerequisites.
 </p><p>To see if the Visual Studio Tools for Office runtime is 
installed, check a registry key on the user computer. To see if the 
Redistributable Primary Interop Assemblies for the 2007 Microsoft Office
 system are installed, check for the component ID of the interop 
assemblies required for your solution. The ExcelAddIn requires the 
Microsoft Excel and Office Shared PIAs.</p>


To configure launch conditions
<ol class="ordered"><li><p>In <strong>Solution Explorer</strong>, 
right-click <strong>ExcelAddInSetup</strong>.</p></li><li><p>Expand <strong>View</strong>.
 </p></li><li><p>Click <strong>Launch</strong><strong>Conditions</strong>.</p></li><li><p>In
 the <strong>Launch Conditions(ExcelAddInSetup)</strong> editor, 
right-click <strong>Requirements on Target Machine</strong>, and then 
click <strong>Add Registry Launch Condition</strong>. This search 
condition searches the registry for a key the Visual Studio Tools for 
Office runtime installs. The value of the key is then available to the 
various pieces of the installer through a named property. The launch 
condition uses the property defined by the search condition to check for
 a certain value.</p></li><li><p>In the <strong>Launch 
Conditions(ExcelAddInSetup)</strong> editor, select the <strong>Search 
for RegistryEntry1</strong> search condition, right-click the condition 
and select <strong>Properties Window</strong>. </p></li><li><p>In the <strong>Properties</strong>
 window, perform the following tasks.</p><ol class="ordered"><li>
Set the value of <strong>(Name)</strong><strong>to Search for VSTO 3.0 
Runtime</strong>.<br><br></li><li>
Change the value of <strong>Property</strong> to <strong>VSTORUNTIME</strong>.<br><br></li><li>
Set the value of <strong>RegKey</strong> to <strong>Software\Microsoft\vsto
 runtime Setup\v9.0.21022</strong><br><br></li><li>
Leave the <strong>Root</strong> property set to <strong>vsdrrHKLM</strong>.<br><br></li><li>
Change the <strong>Value</strong> property to <strong>Install</strong>.<br><br></li></ol><br><br><strong>Figure
 11. Launch Conditions Properties Window – Search for Runtime</strong><br><br><img
 id="2bfd8671-13ea-4621-bccc-b043271e70de" alt="Launch Conditions 
Properties Window" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/IC53930.jpg"
 title="Launch Conditions Properties Window" xmlns=""></li><li><p>In the
 <strong>Launch Conditions(ExcelAddInSetup)</strong> editor, select the <strong>Condition1</strong>
 launch condition, right-click the condition and select <strong>Properties
 Window</strong>. </p></li><li><p>In the <strong>Properties</strong> 
window, perform the following tasks.</p><ol class="ordered"><li>
Set <strong>(Name)</strong> to <strong>Verify VSTO 3.0 Runtime 
availability</strong>.<br><br></li><li>
Change the value of the <strong>Condition</strong> property to the 
following <strong>VSTORUNTIME = "#1"</strong><br><br></li><li>
Leave the <strong>InstallURL</strong> property blank.<br><br></li><li>
Change the value of the <strong>Message</strong> property to <strong>The
 Visual Studio Tools for Office 3.0 Runtime is not installed. Please run
 Setup.exe</strong>.<br><br></li></ol><br><br><strong>Figure 12. Launch 
Conditions Properties Window – Verify Runtime Availability</strong><br><br><img
 id="76ea85d3-14c6-4655-9409-669f7cb019db" alt="Launch Conditions 
Property Window" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/IC85387.jpg"
 title="Launch Conditions Property Window" xmlns=""></li><li><p>In the <strong>Launch
 Conditions(ExcelAddInSetup)</strong> editor, right-click <strong>Requirements
 on Target Machine</strong>, and then click <strong>Add Windows 
Installer Launch Condition</strong>. This launch condition searches for 
the Microsoft Office Excel 2007 Primary Interop Assembly by searching 
for the specific component ID.</p></li><li><p>Right-click <strong>Search
 for Component1</strong> and click <strong>Properties Window</strong> to
 show the properties of the launch condition.</p></li><li><p>In the <strong>Properties</strong>
 window, change the values of the following properties.</p><ol 
class="ordered"><li>
Set the value of the <strong>(Name)</strong> property to <strong>Search 
for Office Excel 2007 PIA</strong><br><br></li><li>
Set the value of the <strong>ComponentID</strong> property to <strong>{1ABEAF09-435F-47D6-9FEB-0AD05D4EF3EA}</strong>.<br><br></li><li>
Set the value of the <strong>Property</strong> property to <strong>HASEXCELPIA</strong>.<br><br></li></ol><br><br><strong>Figure
 13. Launch Conditions Properties Window - Search for Excel PIA</strong><br><br><img
 id="2a4fe2b3-74aa-4534-8756-ee6ba5f4c5ad" alt="Launch Conditions 
Property Window" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/IC2583.jpg"
 title="Launch Conditions Property Window" xmlns=""></li><li><p>In the <strong>Launch
 Conditions(ExcelAddInSetup)</strong> editor, right-click <strong>Condition1</strong>
 and click <strong>Properties</strong><strong>Window</strong> to show 
the properties of the launch condition.</p></li><li><p>Set the 
properties of <strong>Condition1</strong> using the following 
information:</p><ol class="ordered"><li>
Set <strong>(Name)</strong> to <strong>Verify Excel 2007 PIA 
availability</strong>.<br><br></li><li>
Set <strong>Condition</strong> to <strong>HASEXCELPIA</strong>.<br><br></li><li>
Leave <strong>InstallUrl</strong> blank.<br><br></li><li>
Set <strong>Message</strong> to <strong>A required component for 
interacting with Excel 2007 is not available. Please run setup.exe</strong>.<br><br></li></ol><br><br><strong>Figure
 14. Launch Conditions Properties Window - Verify PIA availability</strong><br><br><img
 id="c8da4ef3-438d-448f-be6b-927fc42c1384" alt="Launch Conditions 
Properties Window" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/IC140750.jpg"
 title="Launch Conditions Properties Window" xmlns=""></li><li><p>In the
 <strong>Launch Conditions(ExcelAddInSetup)</strong> editor, right-click
 <strong>Requirements on Target Machine</strong>, and then <strong>click
 Add Windows Installer Launch Condition</strong>. This launch condition 
searches for the Microsoft Office 2007 Shared Primary Interop Assembly 
by searching for the specific component ID.</p></li><li><p>Right-click <strong>Search
 for Component1</strong> and click <strong>Properties</strong><strong>Window</strong>
 to show the properties of the launch condition.</p></li><li><p>In the <strong>Properties</strong><strong>Window</strong>,
 change the values of the following properties:</p><ol class="ordered"><li>
Set the value of the <strong>(Name)</strong> property to <strong>Search 
for Office 2007 Shared PIA</strong><br><br></li><li>
Set the value of the <strong>ComponentID</strong> property to <strong>{FAB10E66-B22C-4274-8647-7CA1BA5EF30F}</strong>.<br><br></li><li>
Set the value of the <strong>Property</strong> property to <strong>HASSHAREDPIA</strong>.<br><br></li></ol><br><br><strong>Figure
 15. Launch Conditions Properties Window - Search for Office Shared PIA</strong><br><br><img
 id="f7738caa-5fe3-4856-a8e4-966cd1a2b593" alt="Launch Conditions 
Properties Window" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/IC64159.jpg"
 title="Launch Conditions Properties Window" xmlns=""></li><li><p>In the
 <strong>Launch Conditions(ExcelAddInSetup)</strong> editor, right-click
 <strong>Condition1</strong> and click <strong>Properties</strong><strong>Window</strong>
 to show the properties of the launch condition.</p></li><li><p>Set the 
properties of <strong>Condition1</strong> using the following 
information:</p><ol class="ordered"><li>
Set <strong>(Name)</strong> to <strong>Verify Office 2007 Shared PIA 
availability</strong>.<br><br></li><li>
Set <strong>Condition</strong> to <strong>HASSHAREDPIA</strong>.<br><br></li><li>
Leave <strong>InstallUrl</strong> blank.<br><br></li><li>
Set <strong>Message</strong> to <strong>A required component for 
interacting with Excel 2007 is not available. Please run setup.exe</strong>.<br><br></li></ol><br><br><strong>Figure
 16. Launch Conditions Properties Window - Verify Office Shared PIA</strong><br><br><img
 id="c14671b3-9d74-4f53-af7d-2fd032c53c32" alt="Launch Conditions 
Properties Window" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/IC16383.jpg"
 title="Launch Conditions Properties Window" xmlns=""></li></ol><p>The 
final set of launch conditions should resemble the following image.</p><br><br><strong>Figure
 17. Final Launch Conditions</strong><br><br><img 
id="2fc6c804-7f54-4038-baf4-95d819e35f34" alt="Final Launch Conditions" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/IC147417.jpg"
 title="Final Launch Conditions" xmlns=""><div class="alert"><table><tbody><tr><th><img
 id="note" alt="Cc563937.note(en-us,office.12).gif" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/030c41d9079671d09a62d8e2c1db6973.gif"
 title="Cc563937.note(en-us,office.12).gif" xmlns="" class="cl_IC101471"><strong>Note:
 </strong></th></tr><tr><td>
You can further refine the launch conditions for the ExcelAddIn 
installation. For instance, it is useful to verify if the actual target 
Office application is installed because each individual component can be
 disabled by the user.<p></p></td></tr></tbody></table><p></p></div><p>Because
 the 2007 Microsoft Office system no longer supports the registration of
 add-ins in the HKEY_LOCAL_MACHINE registry hive, you can no longer 
install the add-in for all-users. The control that allows the selection 
of all-users or the current-user during the installation procedure 
should be hidden.</p>


To configure a single-user installation
<ol class="ordered"><li><p>In the <strong>Solution Explorer</strong>, 
right-click the <strong>ExcelAddInSetup</strong> project, expand <strong>View</strong>
 and select <strong>User</strong><strong>Interface</strong>.</p></li><li><p>In
 the <strong>User Interface (ExcelAddInSetup)</strong> editor, 
right-click <strong>Installation</strong><strong>Folder</strong> and 
select <strong>Properties</strong><strong>Window</strong>. </p></li><li><p>In
 the <strong>Properties</strong> window, set the value of the <strong>InstallAllUsersVisible</strong>
 property to <strong>False</strong>.</p><br><br><strong>Figure 18. 
Single User Installation</strong><br><br><img 
id="21b92cf5-f952-4078-977f-b742b3813e02" alt="Single User Installation"
 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/IC96990.jpg"
 title="Single User Installation" xmlns=""></li></ol><p>To allow 
non-administrative users to install the Visual Studio Tools for Office 
solution, you need to verify that no files are copied to folders that 
are restricted to the user. The application data folder for the user is a
 suitable place to install the solution. </p>


To change the default installation folder
<ol class="ordered"><li><p>In <strong>Solution Explorer</strong>, 
right-click the Setup project, expand <strong>View</strong> and click <strong>File
 System</strong>.</p></li><li><p>In the <strong>File System Editor</strong>,
 right-click the <strong>Application Folder</strong> node and click <strong>Properties</strong><strong>Window</strong>.</p></li><li><p>In
 the <strong>Properties</strong> window, set <strong>DefaultLocation</strong>
 to <strong>[AppDataFolder][Manufacturer]\[ProductName]</strong>. Note 
the slash between the manufacturer and product name. </p><br><br><strong>Figure
 19. Default Installation Folder</strong><br><br><img 
id="cb19989f-11a1-48ad-8f31-947652f4c3e2" alt="Default Installation 
Folder" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/IC7087.jpg"
 title="Default Installation Folder" xmlns=""></li></ol><p>If you 
downloaded a language pack for the Visual Studio Tools for Office 
runtime you should select the appropriate language in the setup project 
properties. Selecting the language for the setup project provides 
localized messages during the setup process as well as for the Visual 
Studio Tools for Office runtime.</p>


To deploy a language pack 
<ol class="ordered"><li><p>In the <strong>Solution Explorer</strong>, 
click the <strong>ExcelAddInSetup</strong> project.</p></li><li><p>In 
the <strong>Properties</strong> window, for the <strong>Localization</strong>
 property, select the language that you want to use. Note that this 
should be a language that you have already downloaded to the appropriate
 location in the bootstrapper directory.</p><br><br><strong>Figure 20. 
Language Pack Properties</strong><br><br><img 
id="9fe91792-4787-4aae-9b28-2bf17de1454d" alt="Language Pack Properties"
 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/IC166451.jpg"
 title="Language Pack Properties" xmlns=""></li></ol><p>The setup 
project is not compiled as part of a general solution compilation 
because the build can take a long time on larger projects. You need to 
manually compile the setup project and copy the resulting files to an 
accessible location.</p>


To build the setup project
<ol class="ordered"><li><p>In the <strong>Solution Explorer</strong>, 
right-click the <strong>ExcelAddInSetup</strong> project and click <strong>Build</strong>.
 </p></li><li><p>Using <strong>Windows</strong><strong>Explorer</strong>,
 navigate to the output directory of the <strong>ExcelAddInSetup</strong>
 project found in the VSTO v3 Deployment Demo\ExcelAddInSetup\Release 
folder. Copy all files to a location that users can access. Sample 
locations include a network share, CD or USB stick.</p></li></ol><p>It 
is a good idea to test the basic setup before you add more advanced 
features to the setup project. You should perform the following steps on
 a test computer where the add-in is not installed. </p>


To test the ExcelAddIn setup
<ol class="ordered"><li><p>Navigate to the location where you copied <strong>ExcelAddInSetup</strong>
 in the previous procedure.</p></li><li><p>Right-click the setup.exe 
file and click <strong>Open</strong> to install the <strong>ExcelAddInSetup</strong>
 add-in. Accept any Software License Terms that appear, and complete the
 setup wizard to install the add-in on the user computer.</p></li></ol><p>When
 setup.exe is executed, the required prerequisite packages are not 
available yet on the target computer. These prerequisites are installed 
before the MSI with the ExcelAddIn customization is installed. The 
verification of prerequisite components using launch conditions is part 
of the MSI. Hence the configured launch conditions are checked after the
 installation of prerequisite components. This allows you to prepare the
 target computer before the MSI is executed. </p><p>Because the user can
 bypass the installation of prerequisite components by not executing 
setup.exe but by executing the MSI directly, the MSI checks the target 
computer using the launch conditions. One visible side-effect is that 
you might be presented with a user interface pertaining to the 
installation of the primary interop assemblies for the 2007 Microsoft 
Office system before the user interface for the installation of your 
Visual Studio Tools for Office solution is displayed.</p><p>You can 
create the trust relationship as part of the installation process 
because running the setup project is considered a trust decision. </p><p>Perform
 the following procedure on a separate test computer.</p>


To test the ExcelAddIn
<ol class="ordered"><li><p>Open Excel. You are presented with a trust 
prompt asking whether it is safe to execute the add-in. </p></li><li><p>Click
 <strong>Install</strong> in the <strong>Microsoft Office Customization 
Installer</strong> dialog box to trust and run the add-in. The following
 section uses other methods to define the trust relationship between 
Excel and your add-in.</p><br><br><strong>Figure 21. Microsoft Office 
Customization Installer</strong><br><br><img 
id="6937e74c-8d83-4a4f-8b02-2646b7684d48" alt="Microsoft Office 
Customization Installer" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/IC125183.jpg"
 title="Microsoft Office Customization Installer" xmlns=""><div 
class="alert"><table><tbody><tr><th><img id="note" 
alt="Cc563937.note(en-us,office.12).gif" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/030c41d9079671d09a62d8e2c1db6973.gif"
 title="Cc563937.note(en-us,office.12).gif" xmlns="" class="cl_IC101471"><strong>Note:
 </strong></th></tr><tr><td>
 This dialog box is somewhat misleading for Visual Studio Tools for 
Office add-ins that can be locally installed using Windows Installer. 
The add-in is actually already installed, but it is not trusted to run 
yet by the user. For locally installed add-ins the Install button does 
not install the add-in, but it creates the trust-relationship to allow 
the add-in to execute.<p></p></td></tr></tbody></table><p></p></div></li><li><p>The
 add-in is executed.</p><br><br><strong>Figure 22. Hello World</strong><br><br><img
 id="00a3e7e5-f2bc-49c5-9629-ddee30f9dc2c" alt="Hello World" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/IC99346.jpg"
 title="Hello World" xmlns=""></li></ol></div><a 
id="VSTO3SolutionPart1_KnownIssues"></a><h1 class="heading">Known Issues</h1><div
 id="sectionSection7" class="section"><p>There is an issue with Visual 
Studio 2008 RTM and registry keys for application-level add-ins. If the 
registry key name used for the Visual Studio Tools for Office solution 
and the name of Visual Studio Tools for Office project inside Visual 
Studio are the same, then during build time Visual Studio 2008 
overwrites the value for the manifest so it matches the Visual Studio 
2005 SE manifest format. To avoid this issue make sure that the registry
 key name differs from the project name such as CompanyName.AddinName. 
This issue is resolved with Visual Studio 2008 SP1.</p></div><a 
id="VSTO3SolutionPart1_Conclusion"></a><h1 class="heading">Conclusion</h1><div
 id="sectionSection8" class="section"><p>This article provides an 
overview of deploying a Visual Studio Tools for Office solution using a 
Visual Studio 2008 Windows Installer package. This article provides a 
walkthrough to show how you can install the prerequisites (the .NET 
Framework 3.5, the VSTO 3.0 runtime, and the Office primary interop 
assemblies), add the project output and manifests, create registry keys 
to load an application-level add-in, and use the ClickOnce prompt to 
grant trust to your solution.</p><p>To expand your installer to also 
handle trust, deploy additional components, and deploy document-level 
solutions, see the walkthrough examples in Deploying a Visual Studio 
Tools for the Office System 3.0 Solution for the 2007 Microsoft Office 
System using Windows Installer (Part 2 of 2). In addition, the second 
article discusses how to modify the Setup project for Vista and provides
 a list of known issues that you may encounter during the process. </p><p>The
 samples in this article include the walkthrough in Deploying a Visual 
Studio Tools for the Office System 3.0 Solution for the 2007 Microsoft 
Office System using Windows Installer (Part 1 of 2) and the three 
walkthroughs in Deploying a Visual Studio Tools for the Office System 
3.0 Solution for the 2007 Microsoft Office System using Windows 
Installer (Part 2 of 2).</p></div><a 
id="VSTO3SolutionPart1_AdditionalResources"></a><h1 class="heading">Additional
 Resources</h1><div id="sectionSection9" class="section"><p><a 
href="http://msdn.microsoft.com/en-us/library/cc616991%28v=office.12%29.aspx">Deploying
 a Visual Studio Tools for the Office System 3.0 Solution for the 2007 
Microsoft Office System Using Windows Installer (Part 2 of 2)</a></p><p><span
 class="unresolvedLink">Deploying Solutions for 2007 Office System with 
ClickOnce Using Visual Studio Tools for the Office System (3.0)</span></p><p><a
 
href="http://msdn.microsoft.com/en-us/library/bb821233%28v=office.12%29.aspx">Deploying
 Solutions for the 2007 Office System with ClickOnce Using Visual Studio
 2008 Professional</a></p><p><a 
href="http://msdn.microsoft.com/en-us/library/ms178739.aspx">How to: 
Install the Visual Studio Tools for Office Runtime</a></p><p><a 
href="http://msdn.microsoft.com/en-us/library/15s06t57.aspx">Office 
Primary Interop Assemblies</a></p><p><a 
href="http://msdn.microsoft.com/en-us/library/bb386106.aspx">Registry 
Entries for Application-Level Add-Ins</a></p><p><a 
href="http://msdn.microsoft.com/en-us/library/ds87aeyf.aspx">Custom 
Document Properties Overview</a></p><p><span class="unresolvedLink">Specifying
 Form Regions in the Windows Registry</span></p><p><a 
href="http://msdn.microsoft.com/en-us/library/bb772072.aspx">Granting 
Trust to Documents (2007 System)</a></p></div><a 
id="VSTO3SolutionPart1_AbouttheAuthors"></a><h1 class="heading">About 
the Authors</h1><div id="sectionSection10" class="section"><p>Wouter van
 Vugt is a Microsoft MVP with Office Open XML technologies and an 
independent consultant focusing on creating Office Business Applications
 (OBAs) with SharePoint, the Office 2007 system and related .NET 
technologies. Wouter is a frequent contributor to developer community 
sites such as <a href="http://openxmldeveloper.org/">OpenXmlDeveloper.org</a>and
 <a href="http://msdn2.microsoft.com/en-us/library/bb879915.aspx" 
target="_blank">MSDN</a>. He has published several white papers and 
articles as well a book available on line titled <span 
class="unresolvedLink">Open XML: Explained e-book</span>. Wouter is the 
founder of Code-Counsel, a Dutch company focusing on delivering 
cutting-edge technical content through a variety of channels. You can 
find out more about Wouter by reading his <span class="unresolvedLink">blog</span>
 and visiting the <a href="http://www.code-counsel.net/">Code-Counsel 
Web site</a>. </p><p>Ted Pattison is a SharePoint MVP, author, trainer 
and the founder of Ted Pattison Group. In the fall of 2005, Ted was 
hired by Microsoft’s Developer Platform Evangelism group to author the 
Ascend developer training curriculum for Windows SharePoint Services 3.0
 and Microsoft Office SharePoint Server 2007. Since that time, Ted has 
been entirely focused on educating professional developers on SharePoint
 2007 technologies. Ted has just finished writing a book for Microsoft 
Press titled <span class="unresolvedLink">Inside Windows SharePoint 
Services 3.0</span> that focuses on how to use SharePoint as a 
development platform for building business solutions. Ted also writes a 
developer-focused column for MSDN Magazine titled <span 
class="unresolvedLink">Office Space</span>.</p></div></div></div></div></div><div
 class="topicEndLine"></div><div id="CommunityContent" 
class="CommunityContent"><div class="CommunityContentContainer"><div 
id="CommunityContentHeader" class="CommunityContentHeader"><div 
class="CommunityContentHeaderTitleContainer"><span 
class="CommunityContentHeaderTitle h1">Community Content</span><a 
href="http://msdn.microsoft.com/en-us/library/community/add/cc563937%28v=office.12%29.aspx"
 title="Add">Add</a></div><div class="CommunityContentFaq"><a 
href="http://msdn.microsoft.com/en-us/library/community-edits.rss?topic=cc563937%7Cen-us%7Coffice.12"
 title="Annotations"><img class="cl_rss_button" alt="Annotations" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/030c41d9079671d09a62d8e2c1db6973.gif"></a><a
 
href="http://msdn.microsoft.com/en-us/library/community-msdnwikifaq.aspx"
 title="FAQ">FAQ</a></div><div style="clear: both;"></div></div><div 
class="Annotation"><a name="21"></a><div class="AnnotationTitle h3"><span>Excellent
 Article </span></div><div class="AnnotationBody">
            
This&nbsp;is&nbsp;the&nbsp;best&nbsp;article&nbsp;I&nbsp;have&nbsp;found,&nbsp;so&nbsp;far,&nbsp;about&nbsp;deploying&nbsp;VSTO&nbsp;applications.<br><br>
Thanks.
        </div><div class="AnnotationHistory"><a 
href="http://msdn.microsoft.com/en-us/library/community/history/cc563937%28v=office.12%29.aspx?id=21"
 title="History" target="_blank">History</a></div><div 
class="HistoryGraphic"><img 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/030c41d9079671d09a62d8e2c1db6973.gif"
 class="cl_rt_cc_line_top" alt=""></div><div class="ModificationHistory"><div
 class="AnnotationAddedContainer"><a class="AddedUserAvatar" 
href="http://msdn.microsoft.com/en-us/library/community/user/421057.aspx"
 title=""><img alt="" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/Image_009.avatr"
 height="34" width="34"></a><ul class="AddedUserData"><li>7/8/2010</li><li><a
 
href="http://msdn.microsoft.com/en-us/library/community/user/421057.aspx">Gerardo
 Melendrez</a></li></ul></div></div></div><div class="AnnotationComplete
 cl_nav_offline_nav_slice"></div><div class="Annotation"><a name="20"></a><div
 class="AnnotationTitle h3"><span>Adding Add-in without setup projects </span></div><div
 class="AnnotationBody">
            
How&nbsp;to&nbsp;add&nbsp;VSTO&nbsp;addins&nbsp;to&nbsp;excel&nbsp;without&nbsp;msi&nbsp;that&nbsp;is&nbsp;mannually?

        </div><div class="AnnotationHistory"><a 
href="http://msdn.microsoft.com/en-us/library/community/history/cc563937%28v=office.12%29.aspx?id=20"
 title="History" target="_blank">History</a></div><div 
class="HistoryGraphic"><img 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/030c41d9079671d09a62d8e2c1db6973.gif"
 class="cl_rt_cc_line_top" alt=""></div><div class="ModificationHistory"><div
 class="AnnotationAddedContainer"><a class="AddedUserAvatar" 
href="http://msdn.microsoft.com/en-us/library/community/user/378829.aspx"
 title=""><img alt="" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/Image_019.avatr"
 height="34" width="34"></a><ul class="AddedUserData"><li>5/3/2010</li><li><a
 
href="http://msdn.microsoft.com/en-us/library/community/user/378829.aspx">APA3</a></li></ul></div></div></div><div
 class="AnnotationComplete cl_nav_offline_nav_slice"></div><div 
class="Annotation"><a name="19"></a><div class="AnnotationTitle h3"><span>outlook
 Addin Setup And Deployment Vs2008 </span></div><div 
class="AnnotationBody">
            Hi&nbsp;,<br><br>
this&nbsp;doucument&nbsp;is&nbsp;very&nbsp;help&nbsp;ful.&nbsp;could&nbsp;you&nbsp;please&nbsp;any&nbsp;good&nbsp;article&nbsp;for&nbsp;setup&nbsp;of&nbsp;outlook&nbsp;addin&nbsp;application&nbsp;in&nbsp;vs&nbsp;2008<br><br>
Thanks&nbsp;&amp;&nbsp;Regards<br>
Tirumalachari&nbsp;Kancharla
        </div><div class="AnnotationHistory"><a 
href="http://msdn.microsoft.com/en-us/library/community/history/cc563937%28v=office.12%29.aspx?id=19"
 title="History" target="_blank">History</a></div><div 
class="HistoryGraphic"><img 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/030c41d9079671d09a62d8e2c1db6973.gif"
 class="cl_rt_cc_line_top" alt=""></div><div class="ModificationHistory"><div
 class="AnnotationAddedContainer"><a class="AddedUserAvatar" 
href="http://msdn.microsoft.com/en-us/library/community/user/1482092.aspx"
 title=""><img alt="" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/Image_013.avatr"
 height="34" width="34"></a><ul class="AddedUserData"><li>4/19/2010</li><li><a
 
href="http://msdn.microsoft.com/en-us/library/community/user/1482092.aspx">tirumalachari</a></li></ul></div></div></div><div
 class="AnnotationComplete cl_nav_offline_nav_slice"></div><div 
class="Annotation"><a name="18"></a><div class="AnnotationTitle h3"><span>So
 hard to read </span></div><div class="AnnotationBody">
            This walkthrough is poorly formatted and is very hard to 
read.<br></div><div class="AnnotationHistory"><a 
href="http://msdn.microsoft.com/en-us/library/community/history/cc563937%28v=office.12%29.aspx?id=18"
 title="History" target="_blank">History</a></div><div 
class="HistoryGraphic"><img 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/030c41d9079671d09a62d8e2c1db6973.gif"
 class="cl_rt_cc_line_top" alt=""></div><div class="ModificationHistory"><div
 class="AnnotationAddedContainer"><a class="AddedUserAvatar" 
href="http://msdn.microsoft.com/en-us/library/community/user/322047.aspx"
 title=""><img alt="" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/Image_018.avatr"
 height="34" width="34"></a><ul class="AddedUserData"><li>3/25/2010</li><li><a
 
href="http://msdn.microsoft.com/en-us/library/community/user/322047.aspx">asadim</a></li></ul></div></div></div><div
 class="AnnotationComplete cl_nav_offline_nav_slice"></div><div 
class="Annotation"><a name="17"></a><div class="AnnotationTitle h3"><span>[TARGETDIR]ExcelAddIn.vsto|vstolocal
 changes to [TARGETDIR]EPMForecaster.dll.manifest during build </span></div><div
 class="AnnotationBody">
            hello,<br><br>This doc worked ok for me, except the registry
 entry part. When I added manifest value as 
[TARGETDIR]ExcelAddIn.vsto|vstolocal and build the project, the value 
automatically changed to [TARGETDIR]EPMForecaster.dll.manifest. Because 
of this issue, the addin was not loading. I changed this value manually 
on the target machine and the addin worked properly. Any idea why the 
value got changed during the build?<br><br>thanks for the hellp<br></div><div
 class="AnnotationHistory"><a 
href="http://msdn.microsoft.com/en-us/library/community/history/cc563937%28v=office.12%29.aspx?id=17"
 title="History" target="_blank">History</a></div><div 
class="HistoryGraphic"><img 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/030c41d9079671d09a62d8e2c1db6973.gif"
 class="cl_rt_cc_line_top" alt=""></div><div class="ModificationHistory"><div
 class="AnnotationAddedContainer"><a class="AddedUserAvatar" 
href="http://msdn.microsoft.com/en-us/library/community/user/557487.aspx"
 title=""><img alt="" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/Image_006.avatr"
 height="34" width="34"></a><ul class="AddedUserData"><li>1/13/2010</li><li><a
 
href="http://msdn.microsoft.com/en-us/library/community/user/557487.aspx">krishna
 kumar1</a></li></ul></div></div></div><div class="AnnotationComplete 
cl_nav_offline_nav_slice"></div><div class="Annotation"><a name="16"></a><div
 class="AnnotationTitle h3"><span>Need to install for all users on 
terminal server </span></div><div class="AnnotationBody">
            Hello<br><br>I need to install my addin for all users on 
some terminal servers. Any Idea or help ?<br><br>Thanks,<br>Farzad<br><br><pre>[tfl - 24 10 09] Hi - and thanks for your post. You should post questions like this to the MSDN Forums at <a>http://forums.microsoft.com/msdn</a> or the MSDN Newsgroups at </pre><pre><a>http://www.microsoft.com/communities/newsgroups/en-us/</a>. You are much more likely get a quicker response using the forums than through the Community Content. For specific help about:<br>Visual Studio  : <a>http://groups.google.com/groups/dir?sel=usenet%3Dmicrosoft.public.vstudio%2C</a>&amp;<br>SQL Server     : <a>http://groups.google.com/groups/dir?sel=usenet%3Dmicrosoft.public.sqlserver%2C</a>&amp;<br>.NET Framework : <a>http://groups.google.com/groups/dir?sel=usenet%3Dmicrosoft.public.dotnet.framework</a><br>PowerShell     : <a>http://groups.google.com/group/microsoft.public.windows.powershell/topics?pli=1</a><br>All Public     : <a>http://groups.google.com/groups/dir?sel=usenet%3Dmicrosoft.public%2C</a>&amp;<br></pre></div><div
 class="AnnotationHistory"><a 
href="http://msdn.microsoft.com/en-us/library/community/history/cc563937%28v=office.12%29.aspx?id=16"
 title="History" target="_blank">History</a></div><div 
class="HistoryGraphic"><img 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/030c41d9079671d09a62d8e2c1db6973.gif"
 class="cl_rt_cc_line_top" alt=""></div><div class="ModificationHistory"><div
 class="AnnotationAddedContainer"><a class="AddedUserAvatar" 
href="http://msdn.microsoft.com/en-us/library/community/user/211035.aspx"
 title=""><img alt="" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/Image_014.avatr"
 height="34" width="34"></a><ul class="AddedUserData"><li>10/19/2009</li><li><a
 
href="http://msdn.microsoft.com/en-us/library/community/user/211035.aspx">frzJalali</a></li></ul></div><div
 class="AnnotationEditedContainer"><a class="EditedUserAvatar" 
href="http://msdn.microsoft.com/en-us/library/community/user/42770.aspx"
 title=""><img alt="" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/Image_015.avatr"
 height="25" width="25"></a><ul><li>
              10/24/2009
              </li><li><a 
href="http://msdn.microsoft.com/en-us/library/community/user/42770.aspx">Thomas
 Lee</a></li></ul></div></div></div><div class="AnnotationComplete 
cl_nav_offline_nav_slice"></div><div class="Annotation"><a name="13"></a><div
 class="AnnotationTitle h3"><span>Deployment manifest requires 
&amp;lt;deployment&amp;gt; section. </span></div><div 
class="AnnotationBody">
            I have completed all steps above. PlugIn is working fine 
from Development environment. But after setup, when I start Excel 2007 
It throws Exception:<br><br><br>************** Exception Text 
**************<br>System.Deployment.Application.InvalidDeploymentException:
 Exception reading manifest from 
file:///C:/Documents%20and%20Settings/Bharat/Application%20Data/CISPL/BSExcelAddInSetup/BSExcelAddIn.dll.manifest:
 the manifest may not be valid or the file could not be opened. ---&gt; 
System.Deployment.Application.InvalidDeploymentException: <strong>Deployment
 manifest is not semantically valid.</strong> ---&gt; 
System.Deployment.Application.InvalidDeploymentException: <strong><u>Deployment
 manifest requires &lt;deployment&gt; section.<br></u></strong>at 
System.Deployment.Application.Manifest.AssemblyManifest.ValidateSemanticsForDeploymentRole()<br>---
 End of inner exception stack trace ---<br>at 
System.Deployment.Application.Manifest.AssemblyManifest.ValidateSemanticsForDeploymentRole()<br>at
 
System.Deployment.Application.Manifest.AssemblyManifest.ValidateSemantics(ManifestType
 manifestType)<br>at 
System.Deployment.Application.ManifestReader.FromDocument(String 
localPath, ManifestType manifestType, Uri sourceUri)<br>--- End of inner
 exception stack trace ---<br>at 
Microsoft.VisualStudio.Tools.Applications.Deployment.ClickOnceAddInDeploymentManager.GetManifests(TimeSpan
 timeout)<br>at 
Microsoft.VisualStudio.Tools.Applications.Deployment.ClickOnceAddInDeploymentManager.InstallAddIn()<br>---------------------------------------------------------------------------------------------------------------------------------------<br><br>I
 have done lot of search on error message but could not found right 
solution. Please help.<br>Bharat Vasant<br><br><strong>[tfl - 23 08 09] 
Hi - and thanks for your post. You should post questions like this to 
the MSDN Forums at </strong><a><strong>http://forums.microsoft.com/msdn</strong></a><strong>
 or the MSDN Newsgroups at </strong><p><a><strong>http://www.microsoft.com/communities/newsgroups/en-us/</strong></a><strong>.
 You are much more likely get a quicker response using the forums than 
through the Community Content. For specific help about:<br>Visual Studio
  : </strong><a><strong>http://groups.google.com/groups/dir?sel=usenet%3Dmicrosoft.public.vstudio%2C</strong></a><strong>&amp;<br>SQL
 Server     : </strong><a><strong>http://groups.google.com/groups/dir?sel=usenet%3Dmicrosoft.public.sqlserver%2C</strong></a><strong>&amp;<br>.NET
 Framework : </strong><a><strong>http://groups.google.com/groups/dir?sel=usenet%3Dmicrosoft.public.dotnet.framework</strong></a><br><strong>PowerShell
     : </strong><a><strong>http://groups.google.com/group/microsoft.public.windows.powershell/topics?pli=1</strong></a><br><strong>All
 Public     : </strong><a><strong>http://groups.google.com/groups/dir?sel=usenet%3Dmicrosoft.public%2C</strong></a><strong>&amp;<br></strong></p></div><div
 class="AnnotationHistory"><a 
href="http://msdn.microsoft.com/en-us/library/community/history/cc563937%28v=office.12%29.aspx?id=13"
 title="History" target="_blank">History</a></div><div 
class="HistoryGraphic"><img 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/030c41d9079671d09a62d8e2c1db6973.gif"
 class="cl_rt_cc_line_top" alt=""></div><div class="ModificationHistory"><div
 class="AnnotationAddedContainer"><a class="AddedUserAvatar" 
href="http://msdn.microsoft.com/en-us/library/community/user/350508.aspx"
 title=""><img alt="" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/Image_003.avatr"
 height="34" width="34"></a><ul class="AddedUserData"><li>4/8/2009</li><li><a
 
href="http://msdn.microsoft.com/en-us/library/community/user/350508.aspx">manifest
 requires deployment sec</a></li></ul></div><div 
class="AnnotationEditedContainer"><a class="EditedUserAvatar" 
href="http://msdn.microsoft.com/en-us/library/community/user/42770.aspx"
 title=""><img alt="" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/Image_015.avatr"
 height="25" width="25"></a><ul><li>
              8/23/2009
              </li><li><a 
href="http://msdn.microsoft.com/en-us/library/community/user/42770.aspx">Thomas
 Lee</a></li></ul></div></div></div><div class="AnnotationComplete 
cl_nav_offline_nav_slice"></div><div class="Annotation"><a name="12"></a><div
 class="AnnotationTitle h3"><span>Can it all be run silently? How? </span></div><div
 class="AnnotationBody">
            Can it all be run silently? How? 
<p><br><br><strong>[tfl - 23 08 09] Hi - and thanks for your post. You 
should post questions like this to the MSDN Forums at </strong><a><strong>http://forums.microsoft.com/msdn</strong></a><strong>
 or the MSDN Newsgroups at </strong></p><p><a><strong>http://www.microsoft.com/communities/newsgroups/en-us/</strong></a><strong>.
 You are much more likely get a quicker response using the forums than 
through the Community Content. For specific help about:<br>Visual Studio
  : </strong><a><strong>http://groups.google.com/groups/dir?sel=usenet%3Dmicrosoft.public.vstudio%2C</strong></a><strong>&amp;<br>SQL
 Server     : </strong><a><strong>http://groups.google.com/groups/dir?sel=usenet%3Dmicrosoft.public.sqlserver%2C</strong></a><strong>&amp;<br>.NET
 Framework : </strong><a><strong>http://groups.google.com/groups/dir?sel=usenet%3Dmicrosoft.public.dotnet.framework</strong></a><br><strong>PowerShell
     : </strong><a><strong>http://groups.google.com/group/microsoft.public.windows.powershell/topics?pli=1</strong></a><br><strong>All
 Public     : </strong><a><strong>http://groups.google.com/groups/dir?sel=usenet%3Dmicrosoft.public%2C</strong></a><strong>&amp;<br></strong></p></div><div
 class="AnnotationHistory"><a 
href="http://msdn.microsoft.com/en-us/library/community/history/cc563937%28v=office.12%29.aspx?id=12"
 title="History" target="_blank">History</a></div><div 
class="HistoryGraphic"><img 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/030c41d9079671d09a62d8e2c1db6973.gif"
 class="cl_rt_cc_line_top" alt=""></div><div class="ModificationHistory"><div
 class="AnnotationAddedContainer"><a class="AddedUserAvatar" 
href="http://msdn.microsoft.com/en-us/library/community/user/341415.aspx"
 title=""><img alt="" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/Image_012.avatr"
 height="34" width="34"></a><ul class="AddedUserData"><li>1/28/2009</li><li><a
 
href="http://msdn.microsoft.com/en-us/library/community/user/341415.aspx">Mark
 B123123</a></li></ul></div><div class="AnnotationEditedContainer"><a 
class="EditedUserAvatar" 
href="http://msdn.microsoft.com/en-us/library/community/user/42770.aspx"
 title=""><img alt="" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/Image_015.avatr"
 height="25" width="25"></a><ul><li>
              8/23/2009
              </li><li><a 
href="http://msdn.microsoft.com/en-us/library/community/user/42770.aspx">Thomas
 Lee</a></li></ul></div></div></div><div class="AnnotationComplete 
cl_nav_offline_nav_slice"></div><div class="Annotation"><a name="10"></a><div
 class="AnnotationTitle h3"><span>Preparing your Development Computer </span></div><div
 class="AnnotationBody"><h3><p>Preparing your Development Computer</p><p>Step
 4 does not make sense, I do not have the following folders...<br></p>
  To prepare the Office ComponentCheck
<p>All Steps do not make sense, I do not have the following folders...<br><br>[tfl
 - 23 08 09] Hi - and thanks for your post. You should post questions 
like this to the MSDN Forums at <a><strong>http://forums.microsoft.com/msdn</strong></a><strong>
 or the MSDN Newsgroups at </strong></p><p><a><strong>http://www.microsoft.com/communities/newsgroups/en-us/</strong></a><strong>.
 You are much more likely get a quicker response using the forums than 
through the Community Content. For specific help about:<br>Visual Studio
  : </strong><a><strong>http://groups.google.com/groups/dir?sel=usenet%3Dmicrosoft.public.vstudio%2C</strong></a><strong>&amp;<br>SQL
 Server     : </strong><a><strong>http://groups.google.com/groups/dir?sel=usenet%3Dmicrosoft.public.sqlserver%2C</strong></a><strong>&amp;<br>.NET
 Framework : </strong><a><strong>http://groups.google.com/groups/dir?sel=usenet%3Dmicrosoft.public.dotnet.framework</strong></a><br><strong>PowerShell
     : </strong><a><strong>http://groups.google.com/group/microsoft.public.windows.powershell/topics?pli=1</strong></a><br><strong>All
 Public     : </strong><a><strong>http://groups.google.com/groups/dir?sel=usenet%3Dmicrosoft.public%2C</strong></a><strong>&amp;<br></strong></p></h3></div><div
 class="AnnotationHistory"><a 
href="http://msdn.microsoft.com/en-us/library/community/history/cc563937%28v=office.12%29.aspx?id=10"
 title="History" target="_blank">History</a></div><div 
class="HistoryGraphic"><img 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/030c41d9079671d09a62d8e2c1db6973.gif"
 class="cl_rt_cc_line_top" alt=""></div><div class="ModificationHistory"><div
 class="AnnotationAddedContainer"><a class="AddedUserAvatar" 
href="http://msdn.microsoft.com/en-us/library/community/user/116811.aspx"
 title=""><img alt="" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/Image_021.avatr"
 height="34" width="34"></a><ul class="AddedUserData"><li>11/14/2008</li><li><a
 
href="http://msdn.microsoft.com/en-us/library/community/user/116811.aspx">eschneider001</a></li></ul></div><div
 class="AnnotationEditedContainer"><a class="EditedUserAvatar" 
href="http://msdn.microsoft.com/en-us/library/community/user/42770.aspx"
 title=""><img alt="" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/Image_015.avatr"
 height="25" width="25"></a><ul><li>
              8/23/2009
              </li><li><a 
href="http://msdn.microsoft.com/en-us/library/community/user/42770.aspx">Thomas
 Lee</a></li></ul></div></div></div><div class="AnnotationComplete 
cl_nav_offline_nav_slice"></div><div class="Annotation"><a name="8"></a><div
 class="AnnotationTitle h3"><span>Development Computer Already Prepared?
 </span></div><div class="AnnotationBody"><p>Apparently at some point, 
the "Preparing Your Development Computer" steps were incorporated into 
something that I have installed in the past. When I went to VS 2008's 
default Bootstrapper directories, the Office 2007 PIA redistributable 
package was already prepared for me, complete with ComponentCheck.exe 
and the o2007pia.msi.<br></p><p>Was this included in VS 2008 SP1 
perhaps? Or did find some Office Tools install at some point and install
 it?</p><p>Just wondering if I can save some time for other people as 
well in preparing their development environments for this walkthrough.<br><br><strong>[tfl
 - 23 08 09] Hi - and thanks for your post. You should post questions 
like this to the MSDN Forums at </strong><a><strong>http://forums.microsoft.com/msdn</strong></a><strong>
 or the MSDN Newsgroups at </strong></p><p><a><strong>http://www.microsoft.com/communities/newsgroups/en-us/</strong></a><strong>.
 You are much more likely get a quicker response using the forums than 
through the Community Content. For specific help about:<br>Visual Studio
  : </strong><a><strong>http://groups.google.com/groups/dir?sel=usenet%3Dmicrosoft.public.vstudio%2C</strong></a><strong>&amp;<br>SQL
 Server     : </strong><a><strong>http://groups.google.com/groups/dir?sel=usenet%3Dmicrosoft.public.sqlserver%2C</strong></a><strong>&amp;<br>.NET
 Framework : </strong><a><strong>http://groups.google.com/groups/dir?sel=usenet%3Dmicrosoft.public.dotnet.framework</strong></a><br><strong>PowerShell
     : </strong><a><strong>http://groups.google.com/group/microsoft.public.windows.powershell/topics?pli=1</strong></a><br><strong>All
 Public     : </strong><a><strong>http://groups.google.com/groups/dir?sel=usenet%3Dmicrosoft.public%2C</strong></a><strong>&amp;<br></strong></p></div><div
 class="AnnotationHistory"><a 
href="http://msdn.microsoft.com/en-us/library/community/history/cc563937%28v=office.12%29.aspx?id=8"
 title="History" target="_blank">History</a></div><div 
class="HistoryGraphic"><img 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/030c41d9079671d09a62d8e2c1db6973.gif"
 class="cl_rt_cc_line_top" alt=""></div><div class="ModificationHistory"><div
 class="AnnotationAddedContainer"><a class="AddedUserAvatar" 
href="http://msdn.microsoft.com/en-us/library/community/user/56104.aspx"
 title=""><img alt="" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/Image_002.avatr"
 height="34" width="34"></a><ul class="AddedUserData"><li>10/30/2008</li><li><a
 
href="http://msdn.microsoft.com/en-us/library/community/user/56104.aspx">miguelito928</a></li></ul></div><div
 class="AnnotationEditedContainer"><a class="EditedUserAvatar" 
href="http://msdn.microsoft.com/en-us/library/community/user/42770.aspx"
 title=""><img alt="" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/Image_015.avatr"
 height="25" width="25"></a><ul><li>
              8/23/2009
              </li><li><a 
href="http://msdn.microsoft.com/en-us/library/community/user/42770.aspx">Thomas
 Lee</a></li></ul></div></div></div><div class="AnnotationComplete 
cl_nav_offline_nav_slice"></div><div class="Annotation"><a name="6"></a><div
 class="AnnotationTitle h3"><span>Known problems on dependecies check 
during a 64bit installation </span></div><div class="AnnotationBody">
            This white paper wont help users to install it on 64bit 
systems. registry entries are fixed, so setup routine wont search into 
Wow6432Node (where vsto runtime is installed).
<p>And btw. there are to many steps to generate a msi file to use it in 
silent mode.</p><p>it should be easier!!!<br></p><br></div><div 
class="AnnotationHistory"><a 
href="http://msdn.microsoft.com/en-us/library/community/history/cc563937%28v=office.12%29.aspx?id=6"
 title="History" target="_blank">History</a></div><div 
class="HistoryGraphic"><img 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/030c41d9079671d09a62d8e2c1db6973.gif"
 class="cl_rt_cc_line_top" alt=""></div><div class="ModificationHistory"><div
 class="AnnotationAddedContainer"><a class="AddedUserAvatar" 
href="http://msdn.microsoft.com/en-us/library/community/user/244976.aspx"
 title=""><img alt="" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/Image_008.avatr"
 height="34" width="34"></a><ul class="AddedUserData"><li>10/20/2008</li><li><a
 
href="http://msdn.microsoft.com/en-us/library/community/user/244976.aspx">Ole
 K</a></li></ul></div><div class="AnnotationEditedContainer"><a 
class="EditedUserAvatar" 
href="http://msdn.microsoft.com/en-us/library/community/user/42770.aspx"
 title=""><img alt="" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/Image_015.avatr"
 height="25" width="25"></a><ul><li>
              8/23/2009
              </li><li><a 
href="http://msdn.microsoft.com/en-us/library/community/user/42770.aspx">Thomas
 Lee</a></li></ul></div></div></div><div class="AnnotationComplete 
cl_nav_offline_nav_slice"></div><div class="Annotation"><a name="3"></a><div
 class="AnnotationTitle h3"><span>This document is unusable </span></div><div
 class="AnnotationBody"><p>The extremely detailed steps in this document
 and its' poor layout make this document impossible to use. As well, 
this document is completely focused on a sample Excel Add-In project but
 I need to install a real world application / document level solution.<br><br>If
 Office solutions are to be widely developed and distributed simpler 
distribution is required along with better documentation. With this 
complexity, I would not recommend any further projects to utilize this 
technology.<br><br>Colin Geis<br>Senior Developer<br>RibbonPearl Systems</p></div><div
 class="AnnotationHistory"><a 
href="http://msdn.microsoft.com/en-us/library/community/history/cc563937%28v=office.12%29.aspx?id=3"
 title="History" target="_blank">History</a></div><div 
class="HistoryGraphic"><img 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/030c41d9079671d09a62d8e2c1db6973.gif"
 class="cl_rt_cc_line_top" alt=""></div><div class="ModificationHistory"><div
 class="AnnotationAddedContainer"><a class="AddedUserAvatar" 
href="http://msdn.microsoft.com/en-us/library/community/user/139547.aspx"
 title=""><img alt="" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/Image_007.avatr"
 height="34" width="34"></a><ul class="AddedUserData"><li>7/1/2008</li><li><a
 
href="http://msdn.microsoft.com/en-us/library/community/user/139547.aspx">Colin
 Geis</a></li></ul></div><div class="AnnotationEditedContainer"><a 
class="EditedUserAvatar" 
href="http://msdn.microsoft.com/en-us/library/community/user/42770.aspx"
 title=""><img alt="" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/Image_015.avatr"
 height="25" width="25"></a><ul><li>
              8/23/2009
              </li><li><a 
href="http://msdn.microsoft.com/en-us/library/community/user/42770.aspx">Thomas
 Lee</a></li></ul></div></div></div><div class="AnnotationComplete 
cl_nav_offline_nav_slice"></div><div class="Annotation"><a name="4"></a><div
 class="AnnotationTitle h3"><span>Deploying Document-Level Solutions </span></div><div
 class="AnnotationBody">
            Colin,<br><br>For the sake of publication, we had to split 
the whitepaper into two parts, and the document-level solution 
deployment information is in part two located at <a>http://msdn.microsoft.com/en-us/library/cc616991.aspx</a>.<br><br>The
 whitepapers are indeed lengthy, but we felt it was better to err on the
 side of caution and completeness than leaving out details. <br><br>The 
layout is the standard formatting that the MSDN Library uses, so I will 
pass on your feedback to that team.<br><br>The VSTO product team does 
understand that deployment is often the most difficult part of Office 
development, so they are continuously working to improve the experience.
 if you have specific feedback for your scenarios and requirements, 
please submit information through the VSTO blog located at <a>http://blogs.msdn.com/vsto/contact.aspx</a>.<br><br>Mary
 Lee, programming writer.
        </div><div class="AnnotationHistory"><a 
href="http://msdn.microsoft.com/en-us/library/community/history/cc563937%28v=office.12%29.aspx?id=4"
 title="History" target="_blank">History</a></div><div 
class="HistoryGraphic"><img 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/030c41d9079671d09a62d8e2c1db6973.gif"
 class="cl_rt_cc_line_top" alt=""></div><div class="ModificationHistory"><div
 class="AnnotationAddedContainer"><a class="AddedUserAvatar" 
href="http://msdn.microsoft.com/en-us/library/community/user/223766.aspx"
 title=""><img alt="" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/Image_005.avatr"
 height="34" width="34"></a><ul class="AddedUserData"><li>7/10/2008</li><li><a
 
href="http://msdn.microsoft.com/en-us/library/community/user/223766.aspx">Mary
 Lee - MSFT</a></li></ul></div><div class="AnnotationEditedContainer"><a
 class="EditedUserAvatar" 
href="http://msdn.microsoft.com/en-us/library/community/user/42770.aspx"
 title=""><img alt="" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/Image_015.avatr"
 height="25" width="25"></a><ul><li>
              8/23/2009
              </li><li><a 
href="http://msdn.microsoft.com/en-us/library/community/user/42770.aspx">Thomas
 Lee</a></li></ul></div></div></div><div class="AnnotationComplete 
cl_nav_offline_nav_slice"></div><div class="Annotation"><a name="1"></a><div
 class="AnnotationTitle h3"><span>Problems with this White Paper </span></div><div
 class="AnnotationBody">
            Hello!<br><br>I tried to build the excel add-in how it is 
described in this article. On the development machine it functions like 
it should. But if I<br>install it on another client machine it won't 
work. The installation behaves normally and all prerequisits are 
installed properly. The registry Keys are created correctly too. At 
Excel startup there is no error. In the COM Addin Window there are no 
Add-ins displayed.<br>What could be the problem that the add-in isn't 
loaded at all?<br>Could that be a localization problem? Cause in VS 2008
 i get some warnings when I start the building.<br><br>One Warning is 
like: The value of the publicKey attribute in visual studio-tools for 
office system 3.0 runtime doesn't match the one of 
"C:\Programme\Microsoft 
SDKs\Windows\v6.0A\Bootstrapper\Packages\VSTOR30\de\vstor_lp_de_30.exe"<br><br>I
 also get no output when i set the VSTO_LOGALERTS and the 
VSTO_SUPPRESSDISPLAYALERTS variables.<br><br>Greets<br><br><strong>[tfl -
 23 08 09] Hi - and thanks for your post. You should post questions like
 this to the MSDN Forums at </strong><a><strong>http://forums.microsoft.com/msdn</strong></a><strong>
 or the MSDN Newsgroups at </strong><p><a><strong>http://www.microsoft.com/communities/newsgroups/en-us/</strong></a><strong>.
 You are much more likely get a quicker response using the forums than 
through the Community Content. For specific help about:<br>Visual Studio
  : </strong><a><strong>http://groups.google.com/groups/dir?sel=usenet%3Dmicrosoft.public.vstudio%2C</strong></a><strong>&amp;<br>SQL
 Server     : </strong><a><strong>http://groups.google.com/groups/dir?sel=usenet%3Dmicrosoft.public.sqlserver%2C</strong></a><strong>&amp;<br>.NET
 Framework : </strong><a><strong>http://groups.google.com/groups/dir?sel=usenet%3Dmicrosoft.public.dotnet.framework</strong></a><br><strong>PowerShell
     : </strong><a><strong>http://groups.google.com/group/microsoft.public.windows.powershell/topics?pli=1</strong></a><br><strong>All
 Public     : </strong><a><strong>http://groups.google.com/groups/dir?sel=usenet%3Dmicrosoft.public%2C</strong></a><strong>&amp;<br></strong></p><br></div><div
 class="AnnotationHistory"><a 
href="http://msdn.microsoft.com/en-us/library/community/history/cc563937%28v=office.12%29.aspx?id=1"
 title="History" target="_blank">History</a></div><div 
class="HistoryGraphic"><img 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/030c41d9079671d09a62d8e2c1db6973.gif"
 class="cl_rt_cc_line_top" alt=""></div><div class="ModificationHistory"><div
 class="AnnotationAddedContainer"><a class="AddedUserAvatar" 
href="http://msdn.microsoft.com/en-us/library/community/user/224439.aspx"
 title=""><img alt="" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/Image_016.avatr"
 height="34" width="34"></a><ul class="AddedUserData"><li>6/19/2008</li><li><a
 
href="http://msdn.microsoft.com/en-us/library/community/user/224439.aspx">ProSnaker</a></li></ul></div><div
 class="AnnotationEditedContainer"><a class="EditedUserAvatar" 
href="http://msdn.microsoft.com/en-us/library/community/user/42770.aspx"
 title=""><img alt="" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/Image_015.avatr"
 height="25" width="25"></a><ul><li>
              8/23/2009
              </li><li><a 
href="http://msdn.microsoft.com/en-us/library/community/user/42770.aspx">Thomas
 Lee</a></li></ul></div></div></div><div class="AnnotationComplete 
cl_nav_offline_nav_slice"></div><div class="Annotation"><a name="14"></a><div
 class="AnnotationTitle h3"><span>Solution: ComponentCheck.cpp fatal 
error C1083: Cannot open include  file: 'windows.h' </span></div><div 
class="AnnotationBody"><div>while running this command,</div><div><span><pre space="preserve">cl.exe /Oxs /MT /GS ComponentCheck.cpp advapi32.lib</pre></span></div><div>If
 you get this error:</div><div><span></span></div><span><div><span></span></div></span><span><p><span></span></p><div><span>Solution:
 ComponentCheck.cpp fatal error C1083: Cannot open include  file: 
'windows.h'</span></div><div><span></span></div><div><span><span><pre>          <span>
            <p>Then </p>
          </span>
        </pre></span></span></div></span><div><span></span></div><div>Run
 this bat file on Visual studio command pormpt</div><span><pre>C:\Program Files\Microsoft Visual Studio 9.0\Common7\Tools\vsvars32.bat</pre></span><div><span><pre space="preserve">      <span>
        <br>
      </span>
    </pre><pre space="preserve">      <span>It will solve this error.</span>
    </pre></span></div></div><div class="AnnotationHistory"><a 
href="http://msdn.microsoft.com/en-us/library/community/history/cc563937%28v=office.12%29.aspx?id=14"
 title="History" target="_blank">History</a></div><div 
class="HistoryGraphic"><img 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/030c41d9079671d09a62d8e2c1db6973.gif"
 class="cl_rt_cc_line_top" alt=""></div><div class="ModificationHistory"><div
 class="AnnotationAddedContainer"><a class="AddedUserAvatar" 
href="http://msdn.microsoft.com/en-us/library/community/user/227054.aspx"
 title=""><img alt="" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/Image_010.avatr"
 height="34" width="34"></a><ul class="AddedUserData"><li>7/25/2009</li><li><a
 
href="http://msdn.microsoft.com/en-us/library/community/user/227054.aspx">maulikModi</a></li></ul></div></div></div><div
 class="AnnotationComplete cl_nav_offline_nav_slice"></div><div 
class="Annotation"><a name="11"></a><div class="AnnotationTitle h3"><span>|vstolocal
 breaks Outlook trust </span></div><div class="AnnotationBody"><span><p><span>Unable
 to use this method because |vstolocal option breaks Outlook 2007 trust 
to VSTO customization when Outlook runs in Administrator Controlled mode
 
(HKEY_CURRENT_USER\Software\Policies\Microsoft\Office\12.0\Outlook\Security<span></span>AdminSecurityMode
 = 3)</span></p></span></div><div class="AnnotationHistory"><a 
href="http://msdn.microsoft.com/en-us/library/community/history/cc563937%28v=office.12%29.aspx?id=11"
 title="History" target="_blank">History</a></div><div 
class="HistoryGraphic"><img 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/030c41d9079671d09a62d8e2c1db6973.gif"
 class="cl_rt_cc_line_top" alt=""></div><div class="ModificationHistory"><div
 class="AnnotationAddedContainer"><a class="AddedUserAvatar" 
href="http://msdn.microsoft.com/en-us/library/community/user/293782.aspx"
 title=""><img alt="" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/Image_017.avatr"
 height="34" width="34"></a><ul class="AddedUserData"><li>11/19/2008</li><li><a
 
href="http://msdn.microsoft.com/en-us/library/community/user/293782.aspx">dkhodak</a></li></ul></div></div></div><div
 class="AnnotationComplete cl_nav_offline_nav_slice"></div><div 
class="Annotation"><a name="9"></a><div class="AnnotationTitle h3"><span>Value
 does not fall within the expected range. </span></div><div 
class="AnnotationBody"><p>ISSUE:</p><p>=========</p><p>If you get "Value
 does not fall within the expected range." with below mentioned 
exception: </p><p>************** Exception Text **************<br>System.ArgumentException:
 Value does not fall within the expected range.<br>at 
Microsoft.VisualStudio.Tools.Applications.Deployment.ClickOnceAddInDeploymentManager.GetManifests(TimeSpan
 timeout)<br>at 
Microsoft.VisualStudio.Tools.Applications.Deployment.ClickOnceAddInDeploymentManager.InstallAddIn()</p><p><br></p><p>RESOLUTION\WORKAROUND</p><p>====================</p><p>Please
 make sure that we are not using any special character as "&amp;" in the
 Manufacturer property of the setup.</p><p>Visit for more details:</p><p><a>http://blogs.msdn.com/brijs/archive/2008/10/31/bug-vsto-3-0-msi-value-does-not-fall-within-the-expected-range-after-installing-vsto-3-0-msi-package-for-outlook-2007.aspx</a></p></div><div
 class="AnnotationHistory"><a 
href="http://msdn.microsoft.com/en-us/library/community/history/cc563937%28v=office.12%29.aspx?id=9"
 title="History" target="_blank">History</a></div><div 
class="HistoryGraphic"><img 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/030c41d9079671d09a62d8e2c1db6973.gif"
 class="cl_rt_cc_line_top" alt=""></div><div class="ModificationHistory"><div
 class="AnnotationAddedContainer"><a class="AddedUserAvatar" 
href="http://msdn.microsoft.com/en-us/library/community/user/315803.aspx"
 title=""><img alt="" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/Image_011.avatr"
 height="34" width="34"></a><ul class="AddedUserData"><li>10/31/2008</li><li><a
 
href="http://msdn.microsoft.com/en-us/library/community/user/315803.aspx">Brijs</a></li></ul></div><div
 class="AnnotationEditedContainer"><a class="EditedUserAvatar" 
href="http://msdn.microsoft.com/en-us/library/community/user/42770.aspx"
 title=""><img alt="" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/Image_015.avatr"
 height="25" width="25"></a><ul><li>
              11/10/2008
              </li><li><a 
href="http://msdn.microsoft.com/en-us/library/community/user/42770.aspx">Thomas
 Lee</a></li></ul></div></div></div><div class="AnnotationComplete 
cl_nav_offline_nav_slice"></div><div class="Annotation"><a name="2"></a><div
 class="AnnotationTitle h3"><span>Steps missing in some procedures </span></div><div
 class="AnnotationBody"><p>In the list of steps for compiling Office 
ComponentCheck, add the following:</p><ol><li>Copy ComponentCheck.cpp 
from the download installation to <b>{SamplesDir}\projects\ComponentCheck</b>.</li><li>If
 you have only C# or VB.NET installed for Visual Studio 2008, you must 
add all of the Visual C++ components before trying to compile 
ComponentCheck. Even if you have cl.exe installed, if the correct C++ 
libraries are not installed, you might get an error such as "Cannot open
 include file: 'excpt.h': No such file or directory."</li></ol><p>In the
 steps to copy the packages into the bootstrapper directory:<br>Before 
"2007 Microsoft Office Primary Interop Assemblies" shows in the 
Prerequisites dialog box, you must copy the product.xml and 
en\package.xml files to C:\Program Files\Microsoft 
SDKs\Windows\v6.0A\Bootstrapper\Packages\Office2007PIA.</p></div><div 
class="AnnotationHistory"><a 
href="http://msdn.microsoft.com/en-us/library/community/history/cc563937%28v=office.12%29.aspx?id=2"
 title="History" target="_blank">History</a></div><div 
class="HistoryGraphic"><img 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/030c41d9079671d09a62d8e2c1db6973.gif"
 class="cl_rt_cc_line_top" alt=""></div><div class="ModificationHistory"><div
 class="AnnotationAddedContainer"><a class="AddedUserAvatar" 
href="http://msdn.microsoft.com/en-us/library/community/user/28815.aspx"
 title=""><img alt="" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/Image.avatr"
 height="34" width="34"></a><ul class="AddedUserData"><li>6/20/2008</li><li><a
 
href="http://msdn.microsoft.com/en-us/library/community/user/28815.aspx">JCorbin</a></li></ul></div><div
 class="AnnotationEditedContainer"><a class="EditedUserAvatar" 
href="http://msdn.microsoft.com/en-us/library/community/user/42770.aspx"
 title=""><img alt="" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/Image_015.avatr"
 height="25" width="25"></a><ul><li>
              11/9/2008
              </li><li><a 
href="http://msdn.microsoft.com/en-us/library/community/user/42770.aspx">Thomas
 Lee</a></li></ul></div></div></div><div class="AnnotationComplete 
cl_nav_offline_nav_slice"></div><div class="Annotation"><a name="7"></a><div
 class="AnnotationTitle h3"><span>app.config </span></div><div 
class="AnnotationBody">
            Good article.
<p>thanks</p><p>Mark</p><br></div><div class="AnnotationHistory"><a 
href="http://msdn.microsoft.com/en-us/library/community/history/cc563937%28v=office.12%29.aspx?id=7"
 title="History" target="_blank">History</a></div><div 
class="HistoryGraphic"><img 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/030c41d9079671d09a62d8e2c1db6973.gif"
 class="cl_rt_cc_line_top" alt=""></div><div class="ModificationHistory"><div
 class="AnnotationAddedContainer"><a class="AddedUserAvatar" 
href="http://msdn.microsoft.com/en-us/library/community/user/306678.aspx"
 title=""><img alt="" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/Image_004.avatr"
 height="34" width="34"></a><ul class="AddedUserData"><li>10/23/2008</li><li><a
 
href="http://msdn.microsoft.com/en-us/library/community/user/306678.aspx">ms10</a></li></ul></div><div
 class="AnnotationEditedContainer"><a class="EditedUserAvatar" 
href="http://msdn.microsoft.com/en-us/library/community/user/306678.aspx"
 title=""><img alt="" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/Image_004.avatr"
 height="25" width="25"></a><ul><li>
              10/24/2008
              </li><li><a 
href="http://msdn.microsoft.com/en-us/library/community/user/306678.aspx">ms10</a></li></ul></div></div></div><div
 class="AnnotationComplete cl_nav_offline_nav_slice"></div><div 
class="Annotation"><a name="5"></a><div class="AnnotationTitle h3"><span>Value
 does not fall within the expected range. </span></div><div 
class="AnnotationBody"><br>Ok, instead of big project inwhich i was not 
sucessful, I start to go step by step, make a new <strong>outlook addin </strong>project
 and shows a message box at addin startup. Did all steps mentioned 
above, I test my outlook addin, got error <br>Value does not fall within
 the expected range. <br><br>************** Exception Text 
**************<br>System.ArgumentException: Value does not fall within 
the expected range.<br>   at 
Microsoft.VisualStudio.Tools.Applications.Deployment.ClickOnceAddInDeploymentManager.GetManifests(TimeSpan
 timeout)<br>   at 
Microsoft.VisualStudio.Tools.Applications.Deployment.ClickOnceAddInDeploymentManager.InstallAddIn()<br><br>Please
 hep from here. This is outlook addin has only a message box. this does 
not seems a security problem.
        </div><div class="AnnotationHistory"><a 
href="http://msdn.microsoft.com/en-us/library/community/history/cc563937%28v=office.12%29.aspx?id=5"
 title="History" target="_blank">History</a></div><div 
class="HistoryGraphic"><img 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/030c41d9079671d09a62d8e2c1db6973.gif"
 class="cl_rt_cc_line_top" alt=""></div><div class="ModificationHistory"><div
 class="AnnotationAddedContainer"><a class="AddedUserAvatar" 
href="http://msdn.microsoft.com/en-us/library/community/user/141688.aspx"
 title=""><img alt="" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/Image_020.avatr"
 height="34" width="34"></a><ul class="AddedUserData"><li>9/22/2008</li><li><a
 
href="http://msdn.microsoft.com/en-us/library/community/user/141688.aspx">Needo</a></li></ul></div></div></div><div
 class="AnnotationComplete cl_nav_offline_nav_slice"></div></div></div></div></div><div
 class="footer"><div id="footer" class="footerContainer cl_footer_slice"><div
 class="footerLogoContainer"><div class="footerContent"><div 
class="copyright">
      © 2010 Microsoft Corporation. All rights reserved.</div><div 
class="footerLogo cl_footer_logo"></div><a 
href="http://msdn.microsoft.com/cc300389.aspx">Terms of Use</a><span 
class="pipe"> | </span><a 
href="http://www.microsoft.com/library/toolbar/3.0/trademarks/en-us.mspx">Trademarks</a><span
 class="pipe"> | </span><a 
href="http://www.microsoft.com/info/privacy.mspx">Privacy Statement</a><span
 class="pipe">| </span><a onclick="javascript:ShowFeedbackDialog();" 
title="Feedback" class="FeedbackLink" href="#footerLink">
      Feedback
        <span class="FeedbackButton clip20x21" id="FeedbackButton"><img 
class="cl_footer_feedback_icon" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/0988b66c1e448ee567fca35fa16b4f24.png"
 alt="Feedback"></span></a><div id="FeedbackContainer" 
class="FeedbackContainer"><form method="post" 
action="/en-us/library/feedback/add/cc563937(v=office.12).aspx"><div 
class="FeedbackTitleContainer"><div class="FeedbackTitle">
            Feedback</div><div class="FeedbackCancel"><a 
href="javascript:;" 
onclick="document.getElementById('FeedbackContainer').style.display = 
'none';">x</a></div></div><div class="FeedbackData"><div 
class="FeedbackInfoText">
            Tell us about your experience...
        </div><div class="QuestionText">
            Did the page load quickly?
        </div><div class="AnswerText"><span>
                Yes<span><input id="searchBox" name="searchBox" 
value="1" type="radio"></span></span><span>
                No<span><input id="searchBox" name="searchBox" value="0"
 type="radio"></span></span></div><div class="QuestionText">
            Do you like the page design?
        </div><div class="AnswerText"><span>
                Yes<span><input id="tabbedCode" name="tabbedCode" 
value="1" type="radio"></span></span><span>
                No<span><input id="tabbedCode" name="tabbedCode" 
value="0" type="radio"></span></span></div><div class="QuestionText">
            How useful is this topic?
        </div><div class="FeedbackGraphicHolder clip269x23"><img alt="" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/0988b66c1e448ee567fca35fa16b4f24.png"
 class="cl_online_scale FeedbackSiderGraphic"></div><div 
class="RadioButtonHolder"><div class="RateRadioOne"><input 
id="topicUseful" name="topicUseful" title="Really disliked it" value="1"
 type="radio"></div><div class="RateRadio"><input id="topicUseful" 
name="topicUseful" title="Disliked it" value="2" type="radio"></div><div
 class="RateRadio"><input id="topicUseful" name="topicUseful" title="OK"
 value="3" type="radio"></div><div class="RateRadio"><input 
id="topicUseful" name="topicUseful" title="Good" value="4" type="radio"></div><div
 class="RateRadioLast"><input id="topicUseful" name="topicUseful" 
title="Really Good" value="5" type="radio"></div></div><div 
class="QuestionText">
            Tell us more
        </div><div class="FeedbackTextAreaContainer"><textarea 
name="feedbackText" cols="25" rows="5" class="FeedbackTextArea" 
onkeyup="LimitText(this, 4000);" onkeydown="LimitText(this, 4000);"></textarea><textarea
 id="feedbackDescription" name="feedbackDescription" cols="25" rows="10"
 style="display: none;" onkeyup="LimitText(this, 4000);" 
onkeydown="LimitText(this, 4000);">Enter description here.</textarea><input
 id="feedbackPriority" name="feedbackPriority" value="" type="hidden"><input
 id="feedbackSourceUrl" name="feedbackSourceUrl" value="" type="hidden"><input
 id="ClientIP" name="ClientIP" value="" type="hidden"><input 
id="ClientOS" name="ClientOS" value="" type="hidden"><input 
id="ClientBrowser" name="ClientBrowser" value="" type="hidden"><input 
id="ClientTime" name="ClientTime" value="" type="hidden"><input 
id="ClientTimeZone" name="ClientTimeZone" value="" type="hidden"></div><div><input
 value="Send" class="FeedbackSubmit" 
onclick="document.getElementById('feedbackDescription').value='';document.getElementById('feedBackVersion').value
 = '-1';" type="submit"></div></div><input id="returnUrl" 
name="returnUrl" 
value="http://msdn.microsoft.com/en-us/library/cc563937(v=office.12).aspx"
 type="hidden"><input id="feedBackVersion" name="feedBackVersion" 
value="1" type="hidden"></form></div></div></div></div></div><div 
class="MetricsContainer"><div class="WebtrendsContainer"><script type="text/javascript" language="javascript">
//<![CDATA[
  var literalNormalizedUrl = '/en-us/library/cc563937(d=lightweight,l=en-us,v=office.12).aspx';
  var wt_nvr_ru = 'WT_NVR_RU';
  var wt_fpcdom = '.microsoft.com';
  var wt_domlist = 'msdn.microsoft.com';
  var wt_pathlist = '';
  var wt_paramlist = 'DCSext.mtps_devcenter';
  var wt_siteid = 'MSDN';
  var gDomain = 'm.webtrends.com';
  var gDcsId = 'dcsmgru7m99k7mqmgrhudo0k8_8c6m';
  var gFpc = 'WT_FPC';
  if (document.cookie.indexOf(gFpc + "=") == -1) {
    document.write("<scr" + "ipt type='text/javascript' src='" + "http" + (window.location.protocol.indexOf('https:') == 0 ? 's' : '') + "://" + gDomain + "/" + gDcsId + "/wtid.js" + "'><\\/scr" + "ipt>");
  }
  var detectedLocale = 'en-us';
  var wtsp = 'msdnlib_hp';
  var gTrackEvents = '0';
/*]]>*/
</script><noscript><div><img alt="DCSIMG" id="Img1" width="1" height="1" src="http://m.webtrends.com/dcsmgru7m99k7mqmgrhudo0k8_8c6m/njs.gif?dcsuri=/nojavascript&amp;WT.js=No" /></div></noscript></div><div
 class="OmnitureContainer"><script type="text/javascript">
  var omni_guid = '760a3c7c-2c4e-4541-832b-e586a259d75e'; 
</script><noscript><a href="http://www.omniture.com" title="Web Analytics"><img src="http://msstonojsmsdn.112.2o7.net/b/ss/msstonojsmsdn/1/H.20.2--NS/0" height="1" width="1" border="0" alt="" /></a></noscript></div><div
 class="WebMetrixContainer"><div class="MetricsContainer"><img alt="Page
 view tracker" 
src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/trans_pixel.gif"
 border="0" height="0" width="0"></div></div></div><script language="javascript" type="text/javascript" src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/broker.js"></script><script type="text/javascript" src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/b20574176f2d4b6028665a10d8a51cdc.js" xmlns="http://www.w3.org/1999/xhtml"></script><script src="Deploying%20a%20Visual%20Studio%20Tools%20for%20the%20Office%20System%203.0%20Solution%20for%20the%202007%20Microsoft%20Office%20System%20Using%20Windows%20Installer%20%28Part%201%20of%202%29_files/broker-config.js"></script></body></html>